Type Alias ParseResult

Source
pub type ParseResult = Result<AST, ParseError<usize, Token, LexicalError>>;
Expand description

The result that is returned when an input string is parsed. If the parse succeeds, the Ok result will be a vector of definitions representing the AST. If the parse fails, the Err will be either an error from the lexer or the parser.

Aliased Type§

pub enum ParseResult {
    Ok(Vec<Definition>),
    Err(ParseError<usize, Token, LexicalError>),
}

Variants§

§1.0.0

Ok(Vec<Definition>)

Contains the success value

§1.0.0

Err(ParseError<usize, Token, LexicalError>)

Contains the error value