Expand description
The Lean 4 frontend for the portable core.
It reads the layout-sensitive subset that the core can represent
faithfully: namespaces, inductive types, definitions (including
equation-compiler style), match, if, let, theorems with their tactic
structure, and a main : IO Unit of IO.println effects. Everything else
is rejected with a precise obligation.
Mirrors js/src/translation/lean.js.
Functions§
- annotate_
layout - Fills in each token’s line, column and whether it starts its line.
- parse_
lean - Reads a Lean program.
- span
- The range from
fromup to the start ofto(the end of input adds nothing).