Equations
- stx.prettyPrint = match stx.unsetTrailing.reprint with | some str => Lean.format str.toFormat | none => Lean.format stx
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Two names are from the same lexical scope if their scoping information modulo MacroScopesView.name
is equal.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
If ref
does not have position information, then try to use macroStack
Instances For
def
Lean.Elab.addMacroStack
{m : Type → Type}
[Monad m]
[Lean.MonadOptions m]
(msgData : Lean.MessageData)
(macroStack : Lean.Elab.MacroStack)
:
Equations
- One or more equations did not get rendered due to their size.
- Lean.Elab.addMacroStack msgData [] = do let __do_lift ← Lean.getOptions if (!Lean.Option.get __do_lift Lean.Elab.pp.macroStack) = true then pure msgData else pure msgData
Instances For
def
Lean.Elab.checkSyntaxNodeKind
{m : Type → Type}
[Monad m]
[Lean.MonadEnv m]
[Lean.MonadError m]
(k : Lean.Name)
:
Instances For
def
Lean.Elab.checkSyntaxNodeKindAtNamespaces
{m : Type → Type}
[Monad m]
[Lean.MonadEnv m]
[Lean.MonadError m]
(k : Lean.Name)
:
Instances For
Equations
- Lean.Elab.checkSyntaxNodeKindAtCurrentNamespaces k = do let ctx ← read Lean.Elab.checkSyntaxNodeKindAtNamespaces k ctx.currNamespace
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
@[implemented_by _private.Lean.Elab.Util.0.Lean.Elab.evalSyntaxConstantUnsafe]
opaque
Lean.Elab.evalSyntaxConstant
(env : Lean.Environment)
(opts : Lean.Options)
(constName : Lean.Name)
:
unsafe def
Lean.Elab.mkElabAttribute
(γ : Type)
(attrBuiltinName attrName parserNamespace typeName : Lean.Name)
(kind : String)
(attrDeclName : Lean.Name := by exact decl_name%)
:
Instances For
Instances For
@[implemented_by Lean.Elab.mkMacroAttributeUnsafe]
Try to expand macro at syntax tree root and return macro declaration name and new syntax if successful.
Return none if all macros threw Macro.Exception.unsupportedSyntax
.
Instances For
- getCurrMacroScope : m Lean.MacroScope
- getNextMacroScope : m Lean.MacroScope
- setNextMacroScope : Lean.MacroScope → m Unit
Instances
@[always_inline]
instance
Lean.Elab.instMonadMacroAdapterOfMonadLift
(m n : Type → Type)
[MonadLift m n]
[Lean.Elab.MonadMacroAdapter m]
:
Equations
- One or more equations did not get rendered due to their size.
def
Lean.Elab.liftMacroM
{m : Type → Type}
{α : Type}
[Monad m]
[Lean.Elab.MonadMacroAdapter m]
[Lean.MonadEnv m]
[Lean.MonadRecDepth m]
[Lean.MonadError m]
[Lean.MonadResolveName m]
[Lean.MonadTrace m]
[Lean.MonadOptions m]
[Lean.AddMessageContext m]
[MonadLiftT IO m]
(x : Lean.MacroM α)
:
m α
Equations
- One or more equations did not get rendered due to their size.
Instances For
@[inline]
def
Lean.Elab.adaptMacro
{m : Type → Type}
[Monad m]
[Lean.Elab.MonadMacroAdapter m]
[Lean.MonadEnv m]
[Lean.MonadRecDepth m]
[Lean.MonadError m]
[Lean.MonadResolveName m]
[Lean.MonadTrace m]
[Lean.MonadOptions m]
[Lean.AddMessageContext m]
[MonadLiftT IO m]
(x : Lean.Macro)
(stx : Lean.Syntax)
:
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
def
Lean.Elab.logException
{m : Type → Type}
[Monad m]
[Lean.MonadLog m]
[Lean.AddMessageContext m]
[Lean.MonadOptions m]
[MonadLiftT IO m]
(ex : Lean.Exception)
:
m Unit
Equations
- One or more equations did not get rendered due to their size.
- Lean.Elab.logException (Lean.Exception.error ref msg) = Lean.logErrorAt ref msg
Instances For
def
Lean.Elab.withLogging
{m : Type → Type}
[Monad m]
[Lean.MonadLog m]
[MonadExcept Lean.Exception m]
[Lean.AddMessageContext m]
[Lean.MonadOptions m]
[MonadLiftT IO m]
(x : m Unit)
:
m Unit
If x
throws an exception, catch it and turn it into a log message (using logException
).
Instances For
def
Lean.Elab.nestedExceptionToMessageData
{m : Type → Type}
[Monad m]
[Lean.MonadLog m]
(ex : Lean.Exception)
:
Instances For
def
Lean.Elab.throwErrorWithNestedErrors
{m : Type → Type}
{α : Type}
[Lean.MonadError m]
[Monad m]
[Lean.MonadLog m]
(msg : Lean.MessageData)
(exs : Array Lean.Exception)
:
m α
Equations
- One or more equations did not get rendered due to their size.