Equations
- Lean.Compiler.LCNF.Phase.toNat x = match x with | Lean.Compiler.LCNF.Phase.base => 0 | Lean.Compiler.LCNF.Phase.mono => 1 | Lean.Compiler.LCNF.Phase.impure => 2
Equations
- Lean.Compiler.LCNF.instLTPhase = { lt := fun l r => Lean.Compiler.LCNF.Phase.toNat l < Lean.Compiler.LCNF.Phase.toNat r }
Equations
- Lean.Compiler.LCNF.instLEPhase = { le := fun l r => Lean.Compiler.LCNF.Phase.toNat l ≤ Lean.Compiler.LCNF.Phase.toNat r }
Equations
- Lean.Compiler.LCNF.instDecidableLtPhaseInstLTPhase = Nat.decLt (Lean.Compiler.LCNF.Phase.toNat p1) (Lean.Compiler.LCNF.Phase.toNat p2)
Equations
- Lean.Compiler.LCNF.instDecidableLePhaseInstLEPhase = Nat.decLe (Lean.Compiler.LCNF.Phase.toNat p1) (Lean.Compiler.LCNF.Phase.toNat p2)
Which occurrence of the pass in the pipeline this is. Some passes, like simp, can occur multiple times in the pipeline. For most passes this value does not matter.
occurrence : NatWhich phase this
Passis supposed to run inphase : Lean.Compiler.LCNF.PhaseResulting phase.
phaseOut : Lean.Compiler.LCNF.PhaseThe name of the
Passname : Lean.NameThe actual pass function, operating on the
Decls.
A single compiler Pass, consisting of the actual pass function operating
on the Decls as well as meta information.
Instances For
Equations
- Lean.Compiler.LCNF.instInhabitedPass = { default := Lean.Compiler.LCNF.Pass.mk 0 Lean.Compiler.LCNF.Phase.base Lean.Compiler.LCNF.Phase.base default fun decls => pure decls }
When the installer is run this function will receive a list of all current
Passes and return a new one, this can modify the list (and thePasses contained within) in any way it wants.install : Array Lean.Compiler.LCNF.Pass → Lean.CoreM (Array Lean.Compiler.LCNF.Pass)
Can be used to install, remove, replace etc. passes by tagging a declaration
of type PassInstaller with the cpass attribute.
Instances For
Equations
- Lean.Compiler.LCNF.instInhabitedPassInstaller = { default := { install := default } }
- passes : Array Lean.Compiler.LCNF.Pass
The PassManager used to store all Passes that will be run within
pipeline.
Instances For
Equations
- Lean.Compiler.LCNF.instInhabitedPassManager = { default := { passes := default } }
Equations
- One or more equations did not get rendered due to their size.
Equations
- Lean.Compiler.LCNF.Pass.mkPerDeclaration name run phase occurrence = Lean.Compiler.LCNF.Pass.mk occurrence phase phase name fun xs => Array.mapM run xs
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- Lean.Compiler.LCNF.PassInstaller.installAtEnd p = { install := fun passes => pure (Array.push passes p) }
Equations
- Lean.Compiler.LCNF.PassInstaller.append passesNew = { install := fun passes => pure (passes ++ passesNew) }
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- Lean.Compiler.LCNF.PassInstaller.run manager installer = do let __do_lift ← Lean.Compiler.LCNF.PassInstaller.install installer manager.passes pure { passes := __do_lift }
Equations
- One or more equations did not get rendered due to their size.