coq-club AT inria.fr
Subject: The Coq mailing list
List archive
- From: Thomas Braibant <thomas.braibant AT gmail.com>
- To: Jason Gross <jasongross9 AT gmail.com>
- Cc: coq-club <coq-club AT inria.fr>
- Subject: Re: [Coq-Club] Pattern matching on hypotheses of certain types
- Date: Thu, 9 Aug 2012 13:43:02 -0400
I think the following does what you want:
Goal forall (n m : nat) (n' m' : unit) (f : nat -> nat -> Type) (f' :
unit -> unit -> Type) (P : nat -> Prop) (fn : P n -> f n m -> f' n'
m'), False.
intros.
match goal with
| [ H : unit -> unit -> _, H1 : appcontext[?H' ?a ?b] |- _ ] =>
constr_eq H H'; pose H
end.
Cheers
Thomas
On Thu, Aug 9, 2012 at 3:48 AM, Jason Gross
<jasongross9 AT gmail.com>
wrote:
> Goal forall (n m : nat) (n' m' : unit) (f : nat -> nat -> Type) (f' : unit
> -> unit -> Type) (P : nat -> Prop) (fn : P n -> f n m -> f' n' m'), False.
> intros.
> match goal with
> | [ H : unit -> unit -> _, H1 : appcontext[?H ?a ?b] |- _ ] => pose
> H
> end.
- [Coq-Club] Pattern matching on hypotheses of certain types, Jason Gross, 08/09/2012
- Re: [Coq-Club] Pattern matching on hypotheses of certain types, Adam Chlipala, 08/09/2012
- Re: [Coq-Club] Pattern matching on hypotheses of certain types, Thomas Braibant, 08/09/2012
Archive powered by MHonArc 2.6.18.