aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthieu Sozeau2017-07-20 18:32:03 +0200
committerMatthieu Sozeau2018-08-15 12:23:21 +0200
commitbef7a78f9b7f2a27d342365107bd9cc992201129 (patch)
tree03d463f7c6c16604b867b6469c23d2957332af8d
parent71aa2992f4e8a6eb2bc64ecf9aa40a9b0bc0f233 (diff)
tacmach: function to gather undef evars of the goal
-rw-r--r--proofs/tacmach.ml5
-rw-r--r--proofs/tacmach.mli4
2 files changed, 8 insertions, 1 deletions
diff --git a/proofs/tacmach.ml b/proofs/tacmach.ml
index 092bb5c276..6036c8cbca 100644
--- a/proofs/tacmach.ml
+++ b/proofs/tacmach.ml
@@ -227,4 +227,9 @@ module New = struct
let pf_nf_evar gl t = nf_evar (project gl) t
+ let pf_undefined_evars gl =
+ let sigma = Proofview.Goal.sigma gl in
+ let ev = Proofview.Goal.goal gl in
+ let evi = Evd.find sigma ev in
+ Evarutil.filtered_undefined_evars_of_evar_info sigma evi
end
diff --git a/proofs/tacmach.mli b/proofs/tacmach.mli
index 31496fb3d5..b4cb2be2b8 100644
--- a/proofs/tacmach.mli
+++ b/proofs/tacmach.mli
@@ -95,7 +95,7 @@ val refine : constr -> tactic
val pr_gls : goal sigma -> Pp.t
val pr_glls : goal list sigma -> Pp.t
-(* Variants of [Tacmach] functions built with the new proof engine *)
+(** Variants of [Tacmach] functions built with the new proof engine *)
module New : sig
val pf_apply : (env -> evar_map -> 'a) -> Proofview.Goal.t -> 'a
val pf_global : Id.t -> Proofview.Goal.t -> GlobRef.t
@@ -139,4 +139,6 @@ module New : sig
val pf_nf_evar : Proofview.Goal.t -> constr -> constr
+ (** Gathers the undefined evars of the given goal. *)
+ val pf_undefined_evars : Proofview.Goal.t -> Evar.Set.t
end