lean2/tests/lean/bug1.lean
Leonardo de Moura b88b98ac22 feat(frontends/lean): try to add definition/theorem as axiom when it fails to be processed
The idea is to avoid a "tsunami" of error messages when a heavily used
theorem breaks in the beginning of the file
2015-03-13 14:47:21 -07:00

23 lines
651 B
Text

prelude definition bool : Type.{1} := Type.{0}
definition and (p q : bool) : bool := ∀ c : bool, (p → q → c) → c
infixl `∧`:25 := and
constant a : bool
-- Error
theorem and_intro1 (p q : bool) (H1 : p) (H2 : q) : a
:= fun (c : bool) (H : p -> q -> c), H H1 H2
-- Error
theorem and_intro2 (p q : bool) (H1 : p) (H2 : q) : p ∧ p
:= fun (c : bool) (H : p -> q -> c), H H1 H2
-- Error
theorem and_intro3 (p q : bool) (H1 : p) (H2 : q) : q ∧ p
:= fun (c : bool) (H : p -> q -> c), H H1 H2
-- Correct
theorem and_intro4 (p q : bool) (H1 : p) (H2 : q) : p ∧ q
:= fun (c : bool) (H : p -> q -> c), H H1 H2
check and_intro4