| 1 |
(************************************************************************) |
| 2 |
(* * The Rocq Prover / The Rocq Development Team *) |
| 3 |
(* v * Copyright INRIA, CNRS and contributors *) |
| 4 |
(* <O___,, * (see version control and CREDITS file for authors & dates) *) |
| 5 |
(* \VV/ **************************************************************) |
| 6 |
(* // * This file is distributed under the terms of the *) |
| 7 |
(* * GNU Lesser General Public License Version 2.1 *) |
| 8 |
(* * (see LICENSE file for the text of the license) *) |
| 9 |
(************************************************************************) |
| 10 |
|
| 11 |
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) |
| 12 |
|
| 13 |
Require Import ssreflect. |
| 14 |
Require Import TestSuite.ssr_mini_mathcomp. |
| 15 |
|
| 16 |
Lemma test1 : forall n m : nat, n = m -> m * m + n * n = n * n + n * n. |
| 17 |
move=> n m E; have [{2}-> _] : n * n = m * n /\ True by move: E => {1}<-. |
| 18 |
by move: E => {3}->. |
| 19 |
Qed. |
| 20 |
|
| 21 |
Lemma test2 : forall n m : nat, True /\ (n = m -> n * n = n * m). |
| 22 |
by move=> n m; constructor=> [|{2}->]. |
| 23 |
Qed. |