Crate rustemo

source ·
Expand description

This crate is the runtime for the generated Rustemo parsers.

Modules§

Macros§

  • Creates error Result from message, file and location
  • Prints with newline to stdout in debug profile
  • Prints without newline to stdout in debug profile
  • Loads generated parser modules from the Cargo OUT_DIR location.

Structs§

  • Shared Packed Parse Forest (SPPF) returned by the GLR parser.
  • An implementation of Right-Nulled GLR parsing (RNGLR)
  • A node/head in the Graph Structured Stack (GSS). Implements Context for GLR parsing.
  • Context implementation for LR parsing
  • An implementation of LR parsing
  • A line-column based location for use where applicable (e.g. plain text).
  • Describes a span from start till end in the parsed input.
  • Returns a slice of the matched input. If no match is possible None is returned.
  • A lexer that operates over string inputs and uses generated string and regex recognizers provided by the parser table.
  • Represents a single token from the input stream.
  • TreeBuilder is a builder that builds a generic concrete parse tree.
  • Value with location. Used in place of parsed values which need locations to report errors during semantic analysis.

Enums§

  • An action executed by the (G)LR Parser during parsing
  • Error type returned in Err variant of Result type from the parser.
  • A position in the input file.
  • A node in the generic tree produced by TreeBuilder

Traits§

  • Builds output during parsing by using semantic actions.
  • Lexer/Parser context is used to keep the state. It provides necessary information to parsers and actions.
  • Input is a sliceable sequence-like type with a concept of length.
  • A builder variant for LR parsing.
  • The trait implemented by all Rustemo lexers
  • The trait implemented by all Rustemo parsers.
  • Provides LR actions and GOTOs given the state and term/nonterm.
  • This trait must be implemented by the parser state type.
  • The trait implemented by types used to recognize tokens in string inputs. Used by StringLexer.

Type Aliases§