Subexpr utilities for delaborator. #
This file defines utilities for MetaM
computations to traverse subexpressions of an expression
in sync with the Nat
"position" values that refer to them.
Equations
Instances For
Equations
- Lean.PrettyPrinter.Delaborator.SubExpr.getExpr = do let __do_lift ← readThe Lean.SubExpr pure __do_lift.expr
Instances For
Equations
- Lean.PrettyPrinter.Delaborator.SubExpr.getPos = do let __do_lift ← readThe Lean.SubExpr pure __do_lift.pos
Instances For
Equations
- Lean.PrettyPrinter.Delaborator.SubExpr.descend child childIdx x = withTheReader Lean.SubExpr (fun (cfg : Lean.SubExpr) => { expr := child, pos := Lean.SubExpr.Pos.push cfg.pos childIdx }) x
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Uses xa
to compute the fold across the arguments of an application,
where xf
provides the initial value and is evaluated in the context of the head of the application.
Uses xa
to compute the fold across up to maxArgs
outermost arguments of an application,
where xf
provides the initial value and is evaluated in the context of the application minus
the arguments being folded across.
Instances For
Runs xf
in the context of Lean.Expr.getBoundedAppFn maxArgs
.
This is equivalent to withBoundedAppFnArgs maxArgs xf pure
.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Instances For
Equations
- Lean.PrettyPrinter.Delaborator.SubExpr.instInhabitedHoleIterator = { default := { curr := default, top := default } }
Equations
- Lean.PrettyPrinter.Delaborator.SubExpr.HoleIterator.toPos iter = iter.curr
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
The positioning scheme guarantees that there will be an infinite number of extra positions
which are never used by Expr
s. The HoleIterator
always points at the next such "hole".
We use these to attach additional Elab.Info
.
Equations
- One or more equations did not get rendered due to their size.