aboutsummaryrefslogtreecommitdiffhomepage
path: root/tactics
diff options
context:
space:
mode:
authorGravatar herbelin <herbelin@85f007b7-540e-0410-9357-904b9bb8a0f7>2003-01-20 00:25:46 +0000
committerGravatar herbelin <herbelin@85f007b7-540e-0410-9357-904b9bb8a0f7>2003-01-20 00:25:46 +0000
commit0a770151ee4dabe240d2fa08dc58f98f334eb9d1 (patch)
tree864654535b52090a326a3e97c4c6580237b44c95 /tactics
parent2a7f5dd469330a25e94cef75f6cea8c3c3ce256c (diff)
Petits bugs
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@3540 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'tactics')
-rw-r--r--tactics/tacinterp.ml9
1 files changed, 7 insertions, 2 deletions
diff --git a/tactics/tacinterp.ml b/tactics/tacinterp.ml
index aa1f37a83..2550bfb5a 100644
--- a/tactics/tacinterp.ml
+++ b/tactics/tacinterp.ml
@@ -79,7 +79,7 @@ type value =
| VRec of value ref
(* Signature for interpretation: val_interp and interpretation functions *)
-and interp_sign =
+type interp_sign =
{ lfun : (identifier * value) list;
lmatch : (int * constr) list;
debug : debug_info }
@@ -834,6 +834,11 @@ let get_debug () = !debug
let eval_ident ist id =
try match List.assoc id ist.lfun with
| VIdentifier id -> id
+ | VConstr c as v when isVar c ->
+ (* This happends e.g. in definitions like "Tac H = Clear H; Intro H" *)
+ (* c is then expected not to belong to the proof context *)
+ (* would be checkable if env were known from eval_ident *)
+ destVar c
| _ -> user_err_loc(loc,"eval_ident",str "should be bound to an identifier")
with Not_found -> id
@@ -1569,7 +1574,7 @@ let interp_tacarg sign ast = (*unvarg*) (val_interp sign ast)
let tac_interp lfun lmatch debug t =
tactic_interp { lfun=lfun; lmatch=lmatch; debug=debug } t
-let interp = tac_interp [] [] (get_debug())
+let interp = fun t -> tac_interp [] [] (get_debug()) t (* Side-effect *)
(* Hides interpretation for pretty-print *)
let hide_interp t ot gl =