yamleam/lexer

YAML lexer — line-oriented, block-style.

Splits the source into lines, drops blank/comment-only lines, and tokenizes each remaining line into a Line(indent, line_number, tokens). The parser consumes the resulting List(Line) using indent comparison.

v0.2 additions:

v0.1 limitations still in force:

Values

pub fn tokenize(
  source: String,
) -> Result(List(token.Line), error.YamlError)

Tokenize a YAML source string into a list of logical lines.

Search Document