| 1 |
Require Import TestSuite.admit. |
| 2 |
(* File reduced by coq-bug-finder from original input, then from 6329 lines to 110 lines, then from 115 lines to 88 lines, then from 93 lines to 72 lines *) |
| 3 |
(* coqc version trunk (September 2014) compiled on Sep 25 2014 2:53:46 with OCaml 4.01.0 |
| 4 |
coqtop version cagnode16:/afs/csail.mit.edu/u/j/jgross/coq-trunk,trunk (bec7e0914f4a7144cd4efa8ffaccc9f72dbdb790) *) |
| 5 |
|
| 6 |
Notation "( x ; y )" := (existT _ x y). |
| 7 |
Notation "x .1" := (projT1 x). |
| 8 |
Class IsEquiv {A B : Type} (f : A -> B) := { equiv_inv : B -> A }. |
| 9 |
Record Equiv A B := { equiv_fun :> A -> B ; equiv_isequiv :> IsEquiv equiv_fun }. |
| 10 |
Notation "A <~> B" := (Equiv A B) (at level 85). |
| 11 |
Axiom IsHProp : Type -> Type. |
| 12 |
Inductive Bool := true | false. |
| 13 |
Definition negb (b : Bool) := if b then false else true. |
| 14 |
Axiom LEM : forall A : Type, IsHProp A -> A + (A -> False). |
| 15 |
Axiom cheat : forall {A},A. |
| 16 |
Module NonPrim. |
| 17 |
Class Contr (A : Type) := { center : A ; contr : (forall y : A, center = y) }. |
| 18 |
Definition Book_6_9 : forall X, X -> X. |
| 19 |
Proof. |
| 20 |
intro X. |
| 21 |
pose proof (@LEM (Contr { f : X <~> X & ~(forall x, f x = x) }) cheat) as contrXEquiv. |
| 22 |
destruct contrXEquiv as [[f H]|H]; [ exact f.1 | exact (fun x => x) ]. |
| 23 |
Defined. |
| 24 |
Lemma Book_6_9_not_id b : Book_6_9 Bool b = negb b. |
| 25 |
Proof. |
| 26 |
unfold Book_6_9. |
| 27 |
destruct (@LEM (Contr { f : Bool <~> Bool & ~(forall x, f x = x) }) _) as [[f H']|H']. |
| 28 |
match goal with |
| 29 |
| [ |- equiv_fun Bool Bool f.1 b = negb b ] => idtac |
| 30 |
| [ |- equiv_fun Bool Bool center.1 b = negb b ] => fail 1 "bad" |
| 31 |
end. |
| 32 |
all:admit. |
| 33 |
Defined. |
| 34 |
End NonPrim. |
| 35 |
Module Prim. |
| 36 |
Set Primitive Projections. |
| 37 |
Class Contr (A : Type) := { center : A ; contr : (forall y : A, center = y) }. |
| 38 |
Definition Book_6_9 : forall X, X -> X. |
| 39 |
Proof. |
| 40 |
intro X. |
| 41 |
pose proof (@LEM (Contr { f : X <~> X & ~(forall x, f x = x) }) cheat) as contrXEquiv. |
| 42 |
destruct contrXEquiv as [[f H]|H]; [ exact (f.1) | exact (fun x => x) ]. |
| 43 |
Defined. |
| 44 |
Lemma Book_6_9_not_id b : Book_6_9 Bool b = negb b. |
| 45 |
Proof. |
| 46 |
unfold Book_6_9. |
| 47 |
destruct (@LEM (Contr { f : Bool <~> Bool & ~(forall x, f x = x) }) _) as [[f H']|H']. |
| 48 |
match goal with |
| 49 |
| [ |- equiv_fun Bool Bool f.1 b = negb b ] => idtac |
| 50 |
| [ |- equiv_fun Bool Bool center.1 b = negb b ] => fail 1 "bad" |
| 51 |
end. (* Tactic failure: bad *) |
| 52 |
all:admit. |
| 53 |
Defined. |
| 54 |
End Prim. |