| 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 |
|
| 15 |
Axiom daemon : False. Ltac myadmit := case: daemon. |
| 16 |
|
| 17 |
Class foo (T : Type) := { n : nat }. |
| 18 |
#[export] Instance five : foo nat := {| n := 5 |}. |
| 19 |
|
| 20 |
Definition bar T {f : foo T} m : Prop := |
| 21 |
@n _ f = m. |
| 22 |
|
| 23 |
Eval compute in (bar nat 7). |
| 24 |
|
| 25 |
Lemma a : True. |
| 26 |
set toto := bar _ 8. |
| 27 |
have titi : bar _ 5. |
| 28 |
reflexivity. |
| 29 |
have titi2 : bar _ 5 := . |
| 30 |
Fail reflexivity. |
| 31 |
by myadmit. |
| 32 |
have totoc (H : bar _ 5) : 3 = 3 := eq_refl. |
| 33 |
move/totoc: nat => _. |
| 34 |
exact I. |
| 35 |
Qed. |
| 36 |
|
| 37 |
Set SsrHave NoTCResolution. |
| 38 |
|
| 39 |
Lemma a' : True. |
| 40 |
set toto := bar _ 8. |
| 41 |
have titi : bar _ 5. |
| 42 |
Fail reflexivity. |
| 43 |
by myadmit. |
| 44 |
have titi2 : bar _ 5 := . |
| 45 |
Fail reflexivity. |
| 46 |
by myadmit. |
| 47 |
have totoc (H : bar _ 5) : 3 = 3 := eq_refl. |
| 48 |
move/totoc: nat => _. |
| 49 |
exact I. |
| 50 |
Qed. |
| 51 |
|
| 52 |
Unset SsrHave NoTCResolution. |
| 53 |
|
| 54 |
#[export] Instance test : foo bool. |
| 55 |
Proof. |
| 56 |
have : foo nat. |
| 57 |
Abort. |