You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import tactic.split_ifs
import tactic.localized
open_locale classical
example (P Q : Prop) (w : if P then (if Q then true else true) else true = true) : true :=
begin
split_ifs at w,
-- 3 goals, no `if`s in `w`
all_goals { trivial, }
end
while currently in mathlib4 we have:
import Mathlib.Tactic.SplitIfs
open Classical
example (P Q : Prop) (w : if P then (if Q then true else true) else true = true) : true := by
split_ifs at w
-- two goals here, and in the first `w : if Q then true else true`
This first came up in porting Logic.Embedding.Basic.
@digama0 my feeling is that we should try to make mathlib4 split_ifs match mathlib3 split_ifs as closely as possible, in order to streamline the porting effort. (Though I think eventually all of the split_ifs usages may become split from Lean 4 core.)
Activity
digama0 commentedon Nov 28, 2022
The new behavior looks more useful. I'm inclined to just mathport
split_ifstorepeat' split_ifor makesplit_ifsa macro for that.dwrensha commentedon Nov 28, 2022
@semorrison thanks for the report.
@digama0 my feeling is that we should try to make mathlib4
split_ifsmatch mathlib3split_ifsas closely as possible, in order to streamline the porting effort. (Though I think eventually all of thesplit_ifsusages may becomesplitfrom Lean 4 core.)fix: update context in recursive calls in split_ifs (#761)