Skip to Content.
Sympa Menu

coq-club - [Coq-Club] Ltac like destruct .. as ...

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

[Coq-Club] Ltac like destruct .. as ...


chronological Thread 
  • From: Jianzhou Zhao <jianzhou AT seas.upenn.edu>
  • To: coq-club AT inria.fr
  • Subject: [Coq-Club] Ltac like destruct .. as ...
  • Date: Thu, 12 Aug 2010 19:29:10 -0400
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; b=VrJyFleJPMnweR+OP3+QsOT9331yCFOKq3+8KPsUqUZjj4hub6WN2EJWK0uoKd9Ea8 yRWzwkhyYZZXOuKRl/BbFpgAVThv8pHj7YlCknZ7SdVQKbkYq6fZ/tlpo5sFUFmY80KB SQrWIbQTgPTIZL63qt1qY+PslMi8pX51NjHWk=

Hello,

I wanted to define a tactical working like
  destruct H as J1 J2 ...
The list of names of J's is with variant length.  I defined:

Ltac destructn H Js :=
  match Js with
  | nil => idtac
  | ?J::nil => rename H into J
  | ?J::?Js' => destruct H as [H J]; bdestructn H Js
  end.

But I failed to figure out how to give a list of Js,
  destructn H (J1::J2::nil)
doesn't work, because J1 J2 are not in the current context.

Is there any syntax like ident(...) in 'Tactic Notation'  to tell Coq
that J1 and J2 are used as identifiers under Ltac? or I should do
anything else?

Thanks a lot.
-- 
Jianzhou



Archive powered by MhonArc 2.6.16.

Top of Page