Crate mitex_parser

source ·
Expand description

Given source strings, MiTeX Parser provides an AST (abstract syntax tree).

§Option: Command Specification

The parser retrieves a command specification which defines shape of commands. With the specification, the parser can parse commands correctly. Otherwise, all commands are parsed as barely names without arguments.

§Produce: AST

It returns an untyped syntax node representing the AST defined by rowan. You can access the AST conveniently with interfaces provided by rowan::SyntaxNode.

The untyped syntax node can convert to typed ones defined in crate::syntax.

The untyped syntax node can also convert to rowan::cursor::SyntaxNode to modify the AST syntactically.

Re-exports§

Modules§

Structs§

Enums§

Functions§

  • Parse the input text with the given command specification and return the untyped syntax tree
  • It is only for internal testing