@[instance_reducible]
Equations
def Lean.Meta.caseValues (mvarId : MVarId) (fvarId : FVarId) (values : Array Expr) (hNamePrefix : Name := `h) (needHyps : Bool := true) :
Split goal ... |- C x, where fvarId is xs id, into values.size + 1 subgoals
..., (h_1 : x = value[0]) |- C value[0]... n)..., (h_n : x = value[n - 1]) |- C value[n - 1]n+1)..., (h_1 : x != value[0]) ... (h_n : x != value[n-1]) |- C xwheren = values.sizeThe type ofxmust have decidable equality.
Remark: the last subgoal is for the "else" catchall case, and its subst is {}.
Remark: the field newHs has size 1 forall but the last subgoal.
If needsHyps = false then the else case comes without hypotheses.
Equations
- Lean.Meta.caseValues mvarId fvarId values hNamePrefix needHyps = Lean.Meta.caseValues.loop✝ fvarId hNamePrefix needHyps 1 mvarId values.toList #[] #[]