aboutsummaryrefslogtreecommitdiffhomepage
path: root/printing
diff options
context:
space:
mode:
authorGravatar Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr>2015-12-27 00:44:58 +0100
committerGravatar Pierre-Marie Pédrot <pierre-marie.pedrot@inria.fr>2015-12-27 01:24:35 +0100
commit77e6eda6388aba117476f6c8445c4b61ebdbc33e (patch)
treef86480d946fe24e3b34358c0711660ba466501a6 /printing
parent223db63e09d3f4b0e779961918b1fedd5cda511d (diff)
Tentative API fix for tactic arguments to be fed to tclWITHHOLES.
The previous implementation was a source of evar leaks if misused, as it created values coming together with their current evar_map. This is dead wrong if the value is not used on the spot. To fix this, we rather return a ['a delayed_open] object. Two argument types were modified: bindings and constr_bindings. The open_constr argument should also be fixed, but it is more entangled and thus I leave it for another commit.
Diffstat (limited to 'printing')
-rw-r--r--printing/pptactic.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/printing/pptactic.ml b/printing/pptactic.ml
index ff83ac3e9..b98738ce3 100644
--- a/printing/pptactic.ml
+++ b/printing/pptactic.ml
@@ -1433,7 +1433,7 @@ let () =
Genprint.register_print0 Constrarg.wit_bindings
(pr_bindings_no_with pr_constr_expr pr_lconstr_expr)
(pr_bindings_no_with (pr_and_constr_expr pr_glob_constr) (pr_and_constr_expr pr_lglob_constr))
- (fun { Evd.it = it } -> pr_bindings_no_with pr_constr pr_lconstr it);
+ (fun it -> pr_bindings_no_with pr_constr pr_lconstr (fst (run_delayed it)));
Genprint.register_print0 Constrarg.wit_constr_may_eval
(pr_may_eval pr_constr_expr pr_lconstr_expr (pr_or_by_notation pr_reference) pr_constr_pattern_expr)
(pr_may_eval (pr_and_constr_expr pr_glob_constr) (pr_and_constr_expr pr_lglob_constr)
@@ -1442,7 +1442,7 @@ let () =
Genprint.register_print0 Constrarg.wit_constr_with_bindings
(pr_with_bindings pr_constr_expr pr_lconstr_expr)
(pr_with_bindings (pr_and_constr_expr pr_glob_constr) (pr_and_constr_expr pr_lglob_constr))
- (fun { Evd.it = it } -> pr_with_bindings pr_constr pr_lconstr it);
+ (fun it -> pr_with_bindings pr_constr pr_lconstr (fst (run_delayed it)));
Genprint.register_print0 Stdarg.wit_int int int int;
Genprint.register_print0 Stdarg.wit_bool pr_bool pr_bool pr_bool;
Genprint.register_print0 Stdarg.wit_unit pr_unit pr_unit pr_unit;