From eaf89ab5428046bb3a7ccf6ccfd602b8b812c454 Mon Sep 17 00:00:00 2001 From: herbelin Date: Sun, 5 Aug 2001 18:46:45 +0000 Subject: Mise en place d'un nouveau Destruct sur le modèle du nouvel Induction git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@1874 85f007b7-540e-0410-9357-904b9bb8a0f7 --- parsing/g_tactic.ml4 | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'parsing') diff --git a/parsing/g_tactic.ml4 b/parsing/g_tactic.ml4 index d8c4ecf089..647a4179e4 100644 --- a/parsing/g_tactic.ml4 +++ b/parsing/g_tactic.ml4 @@ -87,6 +87,10 @@ GEXTEND Gram castedconstrarg: [ [ c = Constr.constr -> <:ast< (CASTEDCOMMAND $c) >> ] ] ; + ident_or_numarg: + [ [ id = identarg -> id + | n = numarg -> n ] ] + ; ident_or_constrarg: [ [ c = Constr.constr -> match c with @@ -303,8 +307,10 @@ GEXTEND Gram | IDENT "Case"; cl = constrarg_binding_list -> <:ast< (Case ($LIST $cl)) >> | IDENT "CaseType"; c = constrarg -> <:ast< (CaseType $c) >> - | IDENT "Destruct"; s = identarg -> <:ast< (Destruct $s) >> + | IDENT "Destruct"; s = ident_or_constrarg -> <:ast< (Destruct $s) >> | IDENT "Destruct"; n = numarg -> <:ast< (Destruct $n) >> + | IDENT "NewDestruct"; s = ident_or_constrarg -> <:ast<(NewDestruct $s)>> + | IDENT "NewDestruct"; n = numarg -> <:ast< (NewDestruct $n) >> | IDENT "Decompose"; IDENT "Record" ; c = constrarg -> <:ast< (DecomposeAnd $c) >> | IDENT "Decompose"; IDENT "Sum"; c = constrarg -> -- cgit v1.2.3