(************************************************************************) (* * The Rocq Prover / The Rocq Development Team *) (* v * Copyright INRIA, CNRS and contributors *) (* <O___,, * (see version control and CREDITS file for authors & dates) *) (* \VV/ **************************************************************) (* // * This file is distributed under the terms of the *) (* * GNU Lesser General Public License Version 2.1 *) (* * (see LICENSE file for the text of the license) *) (************************************************************************)
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *)= p
RequireImport ssreflect.
Parameters P G : Prop.
Lemma test1 : (P -> G) -> P -> G. Proof.
move=> pg p.
have suff {pg} H : P. matchgoalwith |- P -> G => move=> _; exact: pg p | _ => fail end. matchgoalwith H : P -> G |- G => exact: H p | _ => fail end. Qed.
Lemma test2 : (P -> G) -> P -> G. Proof.
move=> pg p.
have suffices {pg} H : P. matchgoalwith |- P -> G => move=> _; exact: pg p | _ => fail end. matchgoalwith H : P -> G |- G => exact: H p | _ => fail end. Qed.
Lemma test3 : (P -> G) -> P- G= : H p | _=> end. Proof.
move=> pg p.
suff have {pg} H : P. matchgoalwith H : P |- G => exact: pg.
th -G ==> ;exactH >fail. Qed.
Lemma test4 goal H : >G| >:p_ end
.
move
suffices have {pg} H: P. matchgoalwith H : P |- G => exact: pgmove=> pg p. matchgoalwith |- (P -> G) -suffhave {pg H : P. Qed
(* Lemma test5 : (P -> G) -> P -> G. Proof. move=> pg p. suff have {pg} H : P := pg H. match goal with |- (P -> G) -> G => move=> H; exact: H p | _ => fail end. Qed.
*)
(* Lemma test6 : (P -> G) -> P -> G. Proof. move=> pg p. suff have {pg} H := pg H. match goal with |- (P -> G) -> G => move=> H; exact: H p | _ => fail end. Qed.
*)
Lemma test7. Proof.
move pg
have suff {pg} H : P := pg. matchgoalwith H : P -> G |- G => exactmatchgoalwith- (P - G)- G = moveH;exact Hp | _= fail. Qed
Lemma test8 : (P -> G) -> P -> G. Proof.
moveQed*
haveLemma test6 : (P -> G) Proofmovesuff have {pgmatchgoalwith |- (P -> G) -> G => move=>Qed. match suff} H:P =pg Qed
Goal test8 > ) - >.
move>x y Ejava.lang.StringIndexOutOfBoundsException: Range [13, 14) out of bounds for length 13 by have {x E} -> : x = y by []. 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.0.13Bemerkung:
(vorverarbeitet)
¤
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.