lean4-htt/tests/lean/run/1827_comment.lean
Leonardo de Moura 421f2c2ae2 fix(library/tactic/subst_tactic): subst was creating type incorrect motive when using dependent elimination
This commit fix a bug reported at comment
https://github.com/leanprover/lean/issues/1827#issuecomment-368258713

Remark: the original problem reported at issue #1827 has nothing to do
with this bug.
2018-02-26 14:02:10 -08:00

17 lines
486 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

lemma subst_weirdness1 {α β : Type} {x : α} {P : Π t : Type, t → Prop}
(H : β = α)
(H' : P α x)
: P β (cast (by cc) x) :=
by { subst β, exact H' }
lemma subst_weirdness2 {α β : Type} {x : α} {P : Π t : Type, t → Prop}
(H : β = α)
(H' : P α x)
: P β (cast (by cc) x) :=
by { cases H, exact H' }
lemma subst_weirdness {α β : Type} {x : α} {P : Π t : Type, t → Prop}
(H : β = α)
(H' : P α x)
: P β (cast (by cc) x) :=
by { subst α, exact H' }