Skip to content

Commit 5840bac

Browse files
committed
Adapt to rocq-prover/rocq#21669 (evaluable_of_global_reference no env arg)
1 parent 598ec5a commit 5840bac

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

template-rocq/src/plugin_core.ml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ let rs_lazy = Genredexpr.Cbv Redops.all_flags
2121
let rs_unfold (env : Environ.env) (gr : global_reference) =
2222
try
2323
Genredexpr.Unfold [Locus.AllOccurrences,
24-
Tacred.evaluable_of_global_reference env gr]
24+
Tacred.evaluable_of_global_reference gr]
2525
with
26-
| _ -> CErrors.user_err
27-
Pp.(str "Constant not found or not a constant: " ++ Printer.pr_global gr)
26+
| Tacred.NotEvaluableRef _ -> CErrors.user_err
27+
Pp.(str "Not a constant: " ++ Printer.pr_global gr ++ str ".")
2828

2929
(* Rocq state related to vernaculars, needed to declare constants,
3030
could be a good idea to add the evar_map / env here as a record *)

template-rocq/src/run_template_monad.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ let unquote_reduction_strategy env evm trm (* of type reductionStrategy *) : Red
3030
| name (* to unfold *) :: _ ->
3131
let name = reduce_all env evm name in
3232
let name = unquote_kn name in
33-
Unfold [Locus.AllOccurrences, Tacred.evaluable_of_global_reference env (GlobRef.ConstRef (Constant.make1 name))]
33+
Unfold [Locus.AllOccurrences, Tacred.evaluable_of_global_reference (GlobRef.ConstRef (Constant.make1 name))]
3434
| _ -> bad_term_verb trm "unquote_reduction_strategy"
3535
else not_supported_verb trm "unquote_reduction_strategy"
3636

0 commit comments

Comments
 (0)