[][src]Trait gcode::Callbacks

pub trait Callbacks {
    fn unexpected_token(
        &mut self,
        _found: TokenKind,
        _span: Span,
        _expected: &[TokenKind]
    ) { ... }
fn unexpected_eof(&mut self, _expected: &[TokenKind]) { ... }
fn mangled_input(&mut self, _input: &str, _span: Span) { ... } }

Callback functions the Parser can use to notify the user of errors encountered while parsing.

Provided methods

fn unexpected_token(
    &mut self,
    _found: TokenKind,
    _span: Span,
    _expected: &[TokenKind]
)

We were looking for one or more tokens, but got a different

fn unexpected_eof(&mut self, _expected: &[TokenKind])

The end-of-input was encountered when more input was expected.

fn mangled_input(&mut self, _input: &str, _span: Span)

Invalid tokens

Loading content...

Implementors

impl Callbacks for Nop[src]

fn unexpected_token(
    &mut self,
    _found: TokenKind,
    _span: Span,
    _expected: &[TokenKind]
)
[src]

fn unexpected_eof(&mut self, _expected: &[TokenKind])[src]

fn mangled_input(&mut self, _input: &str, _span: Span)[src]

impl<'a, C: Callbacks> Callbacks for &'a mut C[src]

Loading content...