- vars : Std.HashMap FVarId Arg
- joinPoints : Std.HashMap FVarId JoinPointId
- nextId : Nat
- subst : Compiler.LCNF.FVarSubst
We keep around a substitution here because we run a second trivial structure elimination when converting to IR. This elimination is aware of the fact that
Voidis irrelevant while the first one in LCNF isn't because LCNF is still pure. However, IR does not allow us to have bindings of the formlet x := ywhich might occur when for example projecting out of a trivial structure where previously a binding would've beenlet x := proj y iand now becomeslet x := y. For this reason we carry around these kinds of bindings in this substitution and apply it whenever we access an fvar in the conversion.
Instances For
@[reducible, inline]
Instances For
Equations
- One or more equations did not get rendered due to their size.
Equations
- x.run = StateRefT'.run' x { }
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- Lean.IR.ToIR.getJoinPointValue fvarId = do let __do_lift ← get pure (__do_lift.joinPoints.get! fvarId)
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
- Lean.IR.ToIR.findDecl n = do let __do_lift ← Lean.getEnv pure (Lean.IR.findEnvDecl __do_lift n)
Instances For
Equations
- Lean.IR.ToIR.addDecl d = Lean.modifyEnv fun (env : Lean.Environment) => Lean.PersistentEnvExtension.addEntry Lean.IR.declMapExt env d
Instances For
Equations
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.nat n) = (Lean.IR.LitVal.num n, if n < UInt32.size then Lean.IR.IRType.tagged else Lean.IR.IRType.tobject)
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.str s) = (Lean.IR.LitVal.str s, Lean.IR.IRType.object)
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.uint8 v_2) = (Lean.IR.LitVal.num v_2.toNat, Lean.IR.IRType.uint8)
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.uint16 v_2) = (Lean.IR.LitVal.num v_2.toNat, Lean.IR.IRType.uint16)
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.uint32 v_2) = (Lean.IR.LitVal.num v_2.toNat, Lean.IR.IRType.uint32)
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.uint64 v_2) = (Lean.IR.LitVal.num v_2.toNat, Lean.IR.IRType.uint64)
- Lean.IR.ToIR.lowerLitValue (Lean.Compiler.LCNF.LitValue.usize v_2) = (Lean.IR.LitVal.num v_2.toNat, Lean.IR.IRType.usize)
Instances For
Equations
Instances For
- expr (e : Expr) : TranslatedProj
- erased : TranslatedProj
Instances For
Equations
- Lean.IR.ToIR.lowerProj base ctorInfo (Lean.IR.CtorFieldInfo.object i irType) = (Lean.IR.ToIR.TranslatedProj.expr (Lean.IR.Expr.proj i base), irType)
- Lean.IR.ToIR.lowerProj base ctorInfo (Lean.IR.CtorFieldInfo.usize i) = (Lean.IR.ToIR.TranslatedProj.expr (Lean.IR.Expr.uproj i base), Lean.IR.IRType.usize)
- Lean.IR.ToIR.lowerProj base ctorInfo (Lean.IR.CtorFieldInfo.scalar sz offset irType) = (Lean.IR.ToIR.TranslatedProj.expr (Lean.IR.Expr.sproj (ctorInfo.size + ctorInfo.usize) offset base), irType)
- Lean.IR.ToIR.lowerProj base ctorInfo Lean.IR.CtorFieldInfo.erased = (Lean.IR.ToIR.TranslatedProj.erased, Lean.IR.IRType.erased)
- Lean.IR.ToIR.lowerProj base ctorInfo Lean.IR.CtorFieldInfo.void = (Lean.IR.ToIR.TranslatedProj.erased, Lean.IR.IRType.void)
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- Lean.IR.ToIR.lowerResultType type arity = liftM (Lean.IR.toIRType (Lean.IR.ToIR.lowerResultType.resultTypeForArity✝ type arity))
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.