HandleExpr #
This module provides helpers reflecting Lean Exprs into MRiscX data.
Fold the optional label expression e? into the running labelmap expression.
Equations
- One or more equations did not get rendered due to their size.
- unwrapWhileCreateLabelmap (some arg) labelmap = pure arg
Instances For
Evaluate an Expr to the UInt64 it denotes.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Evaluate an Expr to the String it denotes.
Equations
- getStrFromExpr e = do let e ← Lean.Meta.whnf e match e with | Lean.Expr.lit (Lean.Literal.strVal s) => pure s | x => Lean.throwError (Lean.toMessageData "Expected a string literal")
Instances For
Extract an Instr from a Code.mk Expr given a program counter value.
This function takes an Expr of type Code.mk and a program counter (UInt64), and returns the Expr of the Instr at that program counter position.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Interpret the first n arguments as UInt64 values, throwing otherwise.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Interpret two argument expressions as a pair of UInt64 values.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Reflect the Instr value out of an Expr.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Reflect the InstructionMap value out of an Expr of type Code.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Return the actual binding body from a lambda function.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Split a conjunction/disjunction type declType into a matching rcases pattern.
Equations
- splitConjDisj declType = splitConjDisjAux✝ (exprDepthBound✝ declType) declType
Instances For
Evaluate a singleton argument expression to the UInt64 it denotes.
Equations
- One or more equations did not get rendered due to their size.