Goalforall (x: nat), exists y, f x = g y. Proof. intros.
eexists.
unify f g.
lazy_match! goalwith
| [ |- ?a ?b = ?rhs ] => unify ($a $b) $rhs end. Abort.
Goalforall (x: nat), exists y, f x = g y. Proof. intros.
eexists.
Unification.unify TransparentState.full 'f 'g.
lazy_match! goalwith
| [ |- ?a ?b = ?rhs ] => Unification.unify_with_full_ts '($a $b) rhs end. Abort.
(* Test that by clause of assert doesn't eat all semicolons: https://github.com/coq/coq/issues/17491 *) Goalforall (a: nat), a = a. Proof. intros. assert (a = a) by Std.reflexivity ();
assumption. Qed.
(* Test that notations in by clause still work: *) Goalforall (a: nat), a = a. Proof. intros. assert (a = a) byexact eq_refl;
assumption. Qed.
Goalforall x, (forall (y : unit), y = x) -> forall (x: unit), x = x. Proof. intros x H y. rewrite -> H at 1 2. reflexivity. Qed.
Goalforall x, (forall (y : unit), x = y) -> forall (x: unit), x = x. Proof. intros x H y. rewrite <- H at 1 2. reflexivity. Qed.
Goalforall x, (forall y : unit, y = x) -> forall y : unit, y = y. Proof. intros x H y.
setoid_rewrite H at 1 2.
setoid_rewrite <- (H y) at 1 2.
setoid_rewrite H. reflexivity. Qed.
Axiom x : unit. Axiom H : forall y : unit, y = x. Goalforall y : unit, y = y. Proof. assert (H2 : tt = x).
{ setoid_rewrite H with (y := tt). reflexivity. }
setoid_rewrite H with (y := tt) at 1 in H2. intros y.
setoid_rewrite H with (y := y) at 1.
setoid_rewrite H with (y := y) at 1. reflexivity. Qed.
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.