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
let some info ← getMatcherInfo? matcherDeclName | throwInternalMisuseError m!"Internal error in `split` tactic: `{matcherDeclName}` is not an auxiliary declaration used to encode `match`-expressions"
252
+
let some info ← getMatcherInfo? matcherDeclName (alsoCasesOn := true) | throwInternalMisuseError m!"Internal error in `split` tactic: `{matcherDeclName}` is not an auxiliary declaration used to encode `match`-expressions"
253
253
let matchEqns ← Match.getEquationsFor matcherDeclName
254
254
-- splitterPre does not have the correct universe elimination level, but this is fine, we only use it to compute the `motiveType`,
255
255
-- and we only care about the `motiveType` arguments, and not the resulting `Sort u`.
defsplitMatch (mvarId : MVarId) (e : Expr) : MetaM (List MVarId) := mvarId.withContext do
305
-
let some app ← matchMatcherApp? e | throwInternalMisuseError m!"Internal error in `split` tactic: Match application expected{indentExpr e}"
305
+
let some app ← matchMatcherApp? e (alsoCasesOn := true) | throwInternalMisuseError m!"Internal error in `split` tactic: Match application expected{indentExpr e}"
306
306
let matchEqns ← Match.getEquationsFor app.matcherName
307
307
let mvarIds ← applyMatchSplitter mvarId app.matcherName app.matcherLevels app.params app.discrs
308
308
let (_, mvarIds) ← mvarIds.foldlM (init := (0, [])) fun (i, mvarIds) mvarId => do
@@ -315,7 +315,7 @@ end Split
315
315
open Split
316
316
317
317
/--
318
-
Splits an `if-then-else` of `match`-expression in the goal target.
318
+
Splits an `if-then-else` or `match`-expression in the goal target.
319
319
If `useNewSemantics` is `true`, the flag `backward.split` is ignored. Recall this flag only affects the split of `if-then-else` expressions.
320
320
-/
321
321
partialdefsplitTarget? (mvarId : MVarId) (splitIte := true) (useNewSemantics := false) : MetaM (Option (List MVarId)) := commitWhenSome? do mvarId.withContext do
0 commit comments