Documentation

Lean.Util.Trace

structure Lean.TraceElem :
Type
Equations
structure Lean.TraceState :
Type
Equations
instance Lean.instMonadTrace (m : TypeType) (n : TypeType) [inst : MonadLift m n] [inst : Lean.MonadTrace m] :
Equations
def Lean.printTraces {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : MonadLiftT IO m] :
Equations
def Lean.resetTraceState {m : TypeType} [inst : Lean.MonadTrace m] :
Equations
Equations
@[inline]
def Lean.isTracingEnabledFor {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : Lean.MonadOptions m] (cls : Lean.Name) :
Equations
@[inline]
def Lean.enableTracing {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] (b : Bool) :
Equations
@[inline]
def Lean.getTraces {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] :
Equations
  • Lean.getTraces = do let s ← Lean.getTraceState pure s.traces
@[inline]
Equations
@[inline]
def Lean.setTraceState {m : TypeType} [inst : Lean.MonadTrace m] (s : Lean.TraceState) :
Equations
def Lean.addTrace {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : Lean.MonadRef m] [inst : Lean.AddMessageContext m] (cls : Lean.Name) (msg : Lean.MessageData) :
Equations
Equations
@[inline]
def Lean.trace {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : Lean.MonadRef m] [inst : Lean.AddMessageContext m] [inst : Lean.MonadOptions m] (cls : Lean.Name) (msg : UnitLean.MessageData) :
Equations
@[inline]
def Lean.traceM {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : Lean.MonadRef m] [inst : Lean.AddMessageContext m] [inst : Lean.MonadOptions m] (cls : Lean.Name) (mkMsg : m Lean.MessageData) :
Equations
@[inline]
def Lean.traceCtx {α : Type} {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : Lean.MonadRef m] [inst : Lean.MonadOptions m] [inst : MonadFinally m] (cls : Lean.Name) (ctx : m α) :
m α
Equations
def Lean.MonadTracer.trace {m : TypeType} [inst : Monad m] [inst : Lean.MonadTrace m] [inst : Lean.MonadRef m] [inst : Lean.AddMessageContext m] [inst : Lean.MonadOptions m] (cls : Lean.Name) (msg : UnitLean.MessageData) :
Equations
def Lean.registerTraceClass (traceClassName : Lean.Name) :
Equations
@[inline]
def Lean.withNestedTraces {α : Type} {m : TypeType} [inst : Monad m] [inst : MonadFinally m] [inst : Lean.MonadTrace m] [inst : Lean.MonadRef m] (x : m α) :
m α
Equations