@[inline]
Equations
- Lean.Expr.ReplaceImpl.cacheSize = 8192 - 1
Equations
- Lean.Expr.ReplaceImpl.Cache.new = { keysResults := mkArray (USize.toNat (2 * Lean.Expr.ReplaceImpl.cacheSize)) (unsafeCast ()) }
@[inline]
Equations
@[inline]
@[inline]
unsafe def
Lean.Expr.ReplaceImpl.Cache.hasResultFor
(c : Lean.Expr.ReplaceImpl.Cache)
(key : Lean.Expr)
:
Equations
- One or more equations did not get rendered due to their size.
@[inline]
unsafe def
Lean.Expr.ReplaceImpl.Cache.getResultFor
(c : Lean.Expr.ReplaceImpl.Cache)
(key : Lean.Expr)
:
Equations
- One or more equations did not get rendered due to their size.
@[inline]
unsafe def
Lean.Expr.ReplaceImpl.Cache.store
(c : Lean.Expr.ReplaceImpl.Cache)
(key : Lean.Expr)
(result : Lean.Expr)
:
Equations
- One or more equations did not get rendered due to their size.
@[inline]
@[inline]
Equations
- Lean.Expr.ReplaceImpl.cache key result = do modify fun x => Lean.Expr.ReplaceImpl.Cache.store x key result pure result
@[specialize #[]]
unsafe def
Lean.Expr.ReplaceImpl.replaceUnsafeM
(f? : Lean.Expr → Option Lean.Expr)
(e : Lean.Expr)
:
Equations
@[specialize #[]]
unsafe def
Lean.Expr.ReplaceImpl.replaceUnsafeM.visit
(f? : Lean.Expr → Option Lean.Expr)
(e : Lean.Expr)
:
Equations
- One or more equations did not get rendered due to their size.
@[inline]
unsafe def
Lean.Expr.ReplaceImpl.replaceUnsafe
(f? : Lean.Expr → Option Lean.Expr)
(e : Lean.Expr)
:
@[specialize #[]]
Equations
- One or more equations did not get rendered due to their size.
- Lean.Expr.replaceNoCache f? e = match f? e with | some eNew => eNew | none => e
@[implemented_by Lean.Expr.ReplaceImpl.replaceUnsafe]
Equations
- Lean.Expr.replace f? e = Lean.Expr.replaceNoCache f? e