WIT syntax tooling for MoonBit
| Package | Intended responsibility |
|---|---|
| span | Implemented: source text, UTF-16 positions, checked slices and span containment |
| diagnostic | Implemented: codes, severity, immutable source labels and recovery details |
| scanner | Implemented: lossless tokens, comments, whitespace and lexical diagnostics |
| ast | Implemented: typed immutable nodes, named child fields and structural validation |
| cst | Implemented: lossless grammar hierarchy, token ranges and subtree reconstruction |
| parser | Implemented: recovering grammar parser and explicit proposal switches |
| traversal | Implemented: AST/CST walks, folds, reductions, events, immutable cursors and rewrites |
| printer | Implemented: stack-safe canonical AST emission with structural round-trip checks |
| formatter | Implemented: CST-aware layout preserving comment text, token order and meaning |
fn version() -> String