One can think of this module as being a partial reimplementation of Lean.Elab.Frontend which also stores a snapshot of the world after each command. Importantly, we allow (re)starting compilation from any snapshot/position in the file for interactive editing purposes.
What Lean knows about the world after the header and each command.
- stx : Lean.Syntax
- mpState : Lean.Parser.ModuleParserState
- cmdState : Lean.Elab.Command.State
Instances For
Instances For
Equations
- s.env = s.cmdState.env
Instances For
Equations
- s.msgLog = s.cmdState.messages
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Instances For
def
Lean.Server.Snapshots.Snapshot.runCommandElabM
{α : Type}
(snap : Lean.Server.Snapshots.Snapshot)
(meta : Lean.Server.DocumentMeta)
(c : Lean.Elab.Command.CommandElabM α)
:
Use the command state in the given snapshot to run a CommandElabM
.
Equations
- One or more equations did not get rendered due to their size.
Instances For
def
Lean.Server.Snapshots.Snapshot.runCoreM
{α : Type}
(snap : Lean.Server.Snapshots.Snapshot)
(meta : Lean.Server.DocumentMeta)
(c : Lean.CoreM α)
:
Run a CoreM
computation using the data in the given snapshot.
Equations
- snap.runCoreM meta c = snap.runCommandElabM meta (Lean.Elab.Command.liftCoreM c)
Instances For
def
Lean.Server.Snapshots.Snapshot.runTermElabM
{α : Type}
(snap : Lean.Server.Snapshots.Snapshot)
(meta : Lean.Server.DocumentMeta)
(c : Lean.Elab.TermElabM α)
:
Run a TermElabM
computation using the data in the given snapshot.
Equations
- snap.runTermElabM meta c = snap.runCommandElabM meta (Lean.Elab.Command.liftTermElabM c)