aboutsummaryrefslogtreecommitdiff
path: root/contrib/interface
diff options
context:
space:
mode:
authorherbelin2007-10-03 12:31:45 +0000
committerherbelin2007-10-03 12:31:45 +0000
commit1bead2a1ef23f2a281613093d7861815279e336d (patch)
tree9eaf1b967dbd270e8525094ae3bed20e1cf260ee /contrib/interface
parent056af27f37f8fb9a00548c88047a86061a624e8b (diff)
Ajout de eelim, ecase, edestruct et einduction (expérimental).
Ajout de l'option with à (e)destruct et (e)induction. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@10169 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'contrib/interface')
-rw-r--r--contrib/interface/pbp.ml2
-rw-r--r--contrib/interface/showproof.ml5
-rw-r--r--contrib/interface/xlate.ml18
3 files changed, 15 insertions, 10 deletions
diff --git a/contrib/interface/pbp.ml b/contrib/interface/pbp.ml
index d96b639531..be99bdde0a 100644
--- a/contrib/interface/pbp.ml
+++ b/contrib/interface/pbp.ml
@@ -175,7 +175,7 @@ let make_pbp_atomic_tactic = function
| PbpElim (hyp_name, names) ->
let bind = List.map (fun s ->(zz,NamedHyp s,make_pbp_pattern s)) names in
TacAtom
- (zz, TacElim ((make_var hyp_name,ExplicitBindings bind),None))
+ (zz, TacElim (false,(make_var hyp_name,ExplicitBindings bind),None))
| PbpTryClear l ->
TacTry (TacAtom (zz, TacClear (false,List.map (fun s -> AI (zz,s)) l)))
| PbpSplit -> TacAtom (zz, TacSplit (false,NoBindings));;
diff --git a/contrib/interface/showproof.ml b/contrib/interface/showproof.ml
index ab4da05e32..e3f6572020 100644
--- a/contrib/interface/showproof.ml
+++ b/contrib/interface/showproof.ml
@@ -1208,11 +1208,12 @@ let rec natural_ntree ig ntree =
| TacExtend (_,"CutIntro",[a]) ->
let _c = out_gen wit_constr a in
natural_cutintro ig lh g gs a ltree
- | TacCase (c,_) -> natural_case ig lh g gs ge (snd c) ltree false
+ | TacCase (_,(c,_)) -> natural_case ig lh g gs ge (snd c) ltree false
| TacExtend (_,"CaseIntro",[a]) ->
let c = out_gen wit_constr a in
natural_case ig lh g gs ge c ltree true
- | TacElim ((c,_),_) -> natural_elim ig lh g gs ge (snd c) ltree false
+ | TacElim (_,(c,_),_) ->
+ natural_elim ig lh g gs ge (snd c) ltree false
| TacExtend (_,"ElimIntro",[a]) ->
let c = out_gen wit_constr a in
natural_elim ig lh g gs ge c ltree true
diff --git a/contrib/interface/xlate.ml b/contrib/interface/xlate.ml
index e2ba05348c..4f98b7396b 100644
--- a/contrib/interface/xlate.ml
+++ b/contrib/interface/xlate.ml
@@ -663,7 +663,8 @@ let xlate_largs_to_id_opt largs =
| _ -> assert false;;
let xlate_int_or_constr = function
- ElimOnConstr a -> CT_coerce_FORMULA_to_FORMULA_OR_INT(xlate_formula a)
+ ElimOnConstr (a,NoBindings) -> CT_coerce_FORMULA_to_FORMULA_OR_INT(xlate_formula a)
+ | ElimOnConstr _ -> xlate_error "TODO: ElimOnConstr with bindings"
| ElimOnIdent(_,i) ->
CT_coerce_ID_OR_INT_to_FORMULA_OR_INT
(CT_coerce_ID_to_ID_OR_INT(xlate_ident i))
@@ -1162,10 +1163,13 @@ and xlate_tac =
CT_generalize_dependent (xlate_formula c)
| TacElimType c -> CT_elim_type (xlate_formula c)
| TacCaseType c -> CT_case_type (xlate_formula c)
- | TacElim ((c1,sl), u) ->
+ | TacElim (false,(c1,sl), u) ->
CT_elim (xlate_formula c1, xlate_bindings sl, xlate_using u)
- | TacCase (c1,sl) ->
+ | TacCase (false,(c1,sl)) ->
CT_casetac (xlate_formula c1, xlate_bindings sl)
+ | TacElim (true,_,_) | TacCase (true,_)
+ | TacNewDestruct (true,_,_,_) | TacNewInduction (true,_,_,_) ->
+ xlate_error "TODO: eelim, ecase, edestruct, einduction"
| TacSimpleInduction h -> CT_induction (xlate_quantified_hypothesis h)
| TacSimpleDestruct h -> CT_destruct (xlate_quantified_hypothesis h)
| TacCut c -> CT_cut (xlate_formula c)
@@ -1207,12 +1211,12 @@ and xlate_tac =
CT_dauto(xlate_int_or_var_opt_to_int_opt a, xlate_int_opt b)
| TacDAuto (a, b, _) ->
xlate_error "TODO: dauto using"
- | TacNewDestruct(a,b,c) ->
- CT_new_destruct (* Julien F. : est-ce correct *)
+ | TacNewDestruct(false,a,b,c) ->
+ CT_new_destruct
(List.map xlate_int_or_constr a, xlate_using b,
xlate_with_names c)
- | TacNewInduction(a,b,c) ->
- CT_new_induction (* Pierre C. : est-ce correct *)
+ | TacNewInduction(false,a,b,c) ->
+ CT_new_induction
(List.map xlate_int_or_constr a, xlate_using b,
xlate_with_names c)
(*| TacInstantiate (a, b, cl) ->