aboutsummaryrefslogtreecommitdiff
path: root/plugins/funind/indfun_common.ml
diff options
context:
space:
mode:
authorMaxime Dénès2017-10-20 11:03:09 +0200
committerMaxime Dénès2017-10-20 11:03:09 +0200
commit8492fa8d2aa0e77b7c571956ee21097977b1df15 (patch)
tree1ac1bd71bb93cef862f4527f0a31923cb5b03cb7 /plugins/funind/indfun_common.ml
parent09525d09e414d3582595ffd141702e69a9a2efb9 (diff)
parent286d387082fb0f86858dce661c789bdcb802c295 (diff)
Merge PR #1095: [stm] Remove state handling from Futures
Diffstat (limited to 'plugins/funind/indfun_common.ml')
-rw-r--r--plugins/funind/indfun_common.ml9
1 files changed, 9 insertions, 0 deletions
diff --git a/plugins/funind/indfun_common.ml b/plugins/funind/indfun_common.ml
index 1e8854249a..76fcd5ec87 100644
--- a/plugins/funind/indfun_common.ml
+++ b/plugins/funind/indfun_common.ml
@@ -549,3 +549,12 @@ type tcc_lemma_value =
| Undefined
| Value of Term.constr
| Not_needed
+
+(* We only "purify" on exceptions *)
+let funind_purify f x =
+ let st = Vernacentries.freeze_interp_state `No in
+ try f x
+ with e ->
+ let e = CErrors.push e in
+ Vernacentries.unfreeze_interp_state st;
+ Exninfo.iraise e