Skip to content

Commit

Permalink
bug(ext): failure on ext lemmas with no hypotheses (leanprover-commun…
Browse files Browse the repository at this point in the history
  • Loading branch information
semorrison authored and digama0 committed Aug 22, 2018
1 parent d18a3a8 commit 58cfe9f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tactic/basic.lean
Expand Up @@ -299,7 +299,7 @@ do h' ← assert h p,
return (h', gs)

meta def try_intros : list name → tactic (list name)
| [] := intros $> []
| [] := try intros $> []
| (x::xs) := (intro x >> try_intros xs) <|> pure (x :: xs)

meta def ext1 (xs : list name) : tactic (list name) :=
Expand Down
10 changes: 10 additions & 0 deletions tests/tactics.lean
Expand Up @@ -339,6 +339,16 @@ end rcases

section ext

@[extensionality] lemma unit.ext (x y : unit) : x = y :=
begin
cases x, cases y, refl
end

example : subsingleton unit :=
begin
split, intros, ext
end

example (x y : ℕ) : true :=
begin
have : x = y,
Expand Down

0 comments on commit 58cfe9f

Please sign in to comment.