Skip to Content.
Sympa Menu

coq-club - [Coq-Club] (e)rewrite with (was: Prop smuggling)

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

[Coq-Club] (e)rewrite with (was: Prop smuggling)


Chronological Thread 
  • From: Arnaud Spiwack <aspiwack AT lix.polytechnique.fr>
  • To: Coq Club <coq-club AT inria.fr>
  • Subject: [Coq-Club] (e)rewrite with (was: Prop smuggling)
  • Date: Tue, 5 Aug 2014 11:19:02 +0200

Only tangentially related to the original discussion but:

AFAIK, there is no "erewrite ... with (var := value)" like there is
for "eapply".
 
Hugo Herbelin pointed out to me, the other day, that erewrite indeed supports "with" bindings:

Goal forall (P Q:nat->Type), (forall (x y:nat), P x = Q y) -> forall x, P x.
Proof.
  intros * h *.
  rewrite h with (y:=x).

When rewriting with several lemmas, one with is allowable per lemma:

Goal forall (P Q T:nat->Type), (forall (x y:nat), P x = Q y) -> (forall (x y:nat), T x = Q y) -> forall x, P x.
Proof.
  intros * h p *.
  rewrite h with (y:=x), <- p with (x:=x).

Hope this is useful.


  • [Coq-Club] (e)rewrite with (was: Prop smuggling), Arnaud Spiwack, 08/05/2014

Archive powered by MHonArc 2.6.18.

Top of Page