toy.combinator

Undocumented in source.

Members

Classes

Alternate
class Alternate

Return either left (higher precedence) or right parser.

Concat
class Concat

Join two parsers together, returning a pair if successful.

Expr
class Expr

Applies a parser repeatedly, delimited by a separator until it fails.

Lazy
class Lazy

For building recursive parsers, delays getting the parser until it's applied.

Optional
class Optional

Returns a successful, even if parsing failed. The unsucessful result is represented as 'null'.

Parser
class Parser

Base parser class with abstract operators.

Phrase
class Phrase

Top-level parser, consumes all tokens passed.

Process
class Process(T)

Manipulates an array of Result values, reducing the result down to a single element.

Repetition
class Repetition

Applies a parser repeatedly until it fails.

Reserved
class Reserved

Parse individual reserved keyword or operator.

TokenTag
class TokenTag

Parse individual token that matches a particular lex.Tag

Structs

Result
struct Result

// Combinators ///// All combinators return a result.

Meta