Skip to main content

Crate gruel_fmt

Crate gruel_fmt 

Source
Expand description

Source formatter for Gruel (ADR-0093).

Parses source with the existing chumsky frontend, walks the AST, and emits canonical text. Comment weaving is delegated to a side trivia scan (ADR-0093 Phase 4).

Re-exports§

pub use printer::Printer;

Modules§

emit
AST walker that emits canonical Gruel text into a Printer.
printer
Output buffer + trivia weaving for the formatter (ADR-0093).
trivia
Trivia scanner (ADR-0093 Phase 4).

Enums§

FmtError
Top-level error returned from format_source.

Functions§

format_source
Format src to canonical Gruel form. Returns Err if the source does not lex or parse.