def
Lean.Meta.substCore
(mvarId : Lean.MVarId)
(hFVarId : Lean.FVarId)
(symm : Bool := false)
(fvarSubst : Lean.Meta.FVarSubst := { map := ∅ })
(clearH : Bool := true)
(tryToSkip : Bool := false)
:
Instances For
Given h : HEq α a α b
in the given goal, produce a new goal where h : Eq α a b
.
If h
is not of the give form, then just return (h, mvarId)
Equations
- One or more equations did not get rendered due to their size.
Instances For
Given x
, try to find an equation of the form heq : x = rhs
or heq : lhs = x
,
and runs substCore
on it. Throws an exception if no such equation is found.
Instances For
Given x
, try to find an equation of the form heq : x = rhs
or heq : lhs = x
,
and runs substCore
on it. Returns none
if no such equation is found, or if substCore
fails.
Instances For
Equations
- Lean.Meta.subst? mvarId hFVarId = Lean.observing? (Lean.Meta.subst mvarId hFVarId)
Instances For
def
Lean.Meta.substCore?
(mvarId : Lean.MVarId)
(hFVarId : Lean.FVarId)
(symm : Bool := false)
(fvarSubst : Lean.Meta.FVarSubst := { map := ∅ })
(clearH : Bool := true)
(tryToSkip : Bool := false)
:
Equations
- Lean.Meta.substCore? mvarId hFVarId symm fvarSubst clearH tryToSkip = Lean.observing? (Lean.Meta.substCore mvarId hFVarId symm fvarSubst clearH tryToSkip)
Instances For
Equations
- Lean.Meta.trySubstVar mvarId hFVarId = do let __do_lift ← Lean.Meta.substVar? mvarId hFVarId pure (__do_lift.getD mvarId)