Overview of @lezer/lr
mainLezer is an incremental GLR (Generalized LR) parser designed for use in editors or similar systems. It is optimized for speed and compactness, making it suitable for maintaining a current program representation during real-time edits and in the presence of syntax errors.
Key characteristics:
- Incremental Parsing: Efficiently updates the syntax tree as the input changes.
- Compactness: Prioritizes small parser table files and a lightweight syntax tree. Syntax tree nodes are minimal 'blobs' containing only a start position, end position, tag, and a set of child nodes.
- Runtime Library: This package (
@lezer/lr) provides the runtime engine that executes parsers generated by@lezer/generator.