summaryrefslogtreecommitdiff
path: root/library/states.mli
diff options
context:
space:
mode:
authorGravatar Enrico Tassi <gareuselesinge@debian.org>2015-01-25 14:42:51 +0100
committerGravatar Enrico Tassi <gareuselesinge@debian.org>2015-01-25 14:42:51 +0100
commit7cfc4e5146be5666419451bdd516f1f3f264d24a (patch)
treee4197645da03dc3c7cc84e434cc31d0a0cca7056 /library/states.mli
parent420f78b2caeaaddc6fe484565b2d0e49c66888e5 (diff)
Imported Upstream version 8.5~beta1+dfsg
Diffstat (limited to 'library/states.mli')
-rw-r--r--library/states.mli19
1 files changed, 11 insertions, 8 deletions
diff --git a/library/states.mli b/library/states.mli
index 9474d831..66de1490 100644
--- a/library/states.mli
+++ b/library/states.mli
@@ -1,6 +1,6 @@
(************************************************************************)
(* v * The Coq Proof Assistant / The Coq Development Team *)
-(* <O___,, * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999-2014 *)
+(* <O___,, * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999-2015 *)
(* \VV/ **************************************************************)
(* // * This file is distributed under the terms of the *)
(* * GNU Lesser General Public License Version 2.1 *)
@@ -17,19 +17,22 @@ val intern_state : string -> unit
val extern_state : string -> unit
type state
-val freeze : unit -> state
+val freeze : marshallable:Summary.marshallable -> state
val unfreeze : state -> unit
-(** {6 Rollback } *)
+val summary_of_state : state -> Summary.frozen
-(** [with_heavy_rollback f x] applies [f] to [x] and restores the
- state of the whole system as it was before the evaluation if an exception
- is raised. *)
-val with_heavy_rollback : ('a -> 'b) -> (exn -> exn) -> 'a -> 'b
+(** {6 Rollback } *)
(** [with_state_protection f x] applies [f] to [x] and restores the
- state of the whole system as it was before the evaluation of f *)
+ state of the whole system as it was before applying [f] *)
val with_state_protection : ('a -> 'b) -> 'a -> 'b
+(** [with_state_protection_on_exception f x] applies [f] to [x] and restores the
+ state of the whole system as it was before applying [f] only if an
+ exception is raised. Unlike [with_state_protection] it also takes into
+ account the proof state *)
+
+val with_state_protection_on_exception : ('a -> 'b) -> 'a -> 'b