aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pretyping/tacred.ml6
-rw-r--r--pretyping/tacred.mli4
2 files changed, 3 insertions, 7 deletions
diff --git a/pretyping/tacred.ml b/pretyping/tacred.ml
index 1242b84146..b42318a524 100644
--- a/pretyping/tacred.ml
+++ b/pretyping/tacred.ml
@@ -789,11 +789,9 @@ let make_flag f =
let red_expr_tab = ref Stringmap.empty
-type generic_reduction_function = constr -> reduction_function
-
let declare_red_expr s f =
try
- let _ = Stringmap.find s in
+ let _ = Stringmap.find s !red_expr_tab in
error ("There is already a reduction expression of name "^s)
with Not_found ->
red_expr_tab := Stringmap.add s f !red_expr_tab
@@ -807,7 +805,7 @@ let reduction_of_redexp = function
| Unfold ubinds -> unfoldn ubinds
| Fold cl -> fold_commands cl
| Pattern lp -> pattern_occs lp
- | ExtraRedExpr (s,c) -> Stringmap.find s !red_expr_tab c
+ | ExtraRedExpr (s,c) -> Stringmap.find s !red_expr_tab
(* Used in several tactics. *)
diff --git a/pretyping/tacred.mli b/pretyping/tacred.mli
index 0224a97685..1d801c5a4b 100644
--- a/pretyping/tacred.mli
+++ b/pretyping/tacred.mli
@@ -76,9 +76,7 @@ type red_expr = (constr, evaluable_global_reference) red_expr_gen
val reduction_of_redexp : red_expr -> reduction_function
-type generic_reduction_function = constr -> reduction_function
-
-val declare_red_expr : string -> generic_reduction_function -> unit
+val declare_red_expr : string -> reduction_function -> unit
(* Opaque and Transparent commands. *)
val set_opaque_const : section_path -> unit