pub enum Reply<'i> {
Success {
tokens: Vec<Token<'i>>,
state: State<'i>,
},
Failure,
Error(ParseError),
}Expand description
The outcome of applying a parser to a State.
Variants§
Success
The parser matched; tokens are accumulated; state is the updated state.
Failure
The parser did not match; no input was consumed; the state is unchanged. The caller may try an alternative.
Error(ParseError)
The parser encountered an unrecoverable error after committing to a branch. Alternatives are not tried — this propagates up the call stack unchanged.
Trait Implementations§
Auto Trait Implementations§
impl<'i> Freeze for Reply<'i>
impl<'i> RefUnwindSafe for Reply<'i>
impl<'i> Send for Reply<'i>
impl<'i> Sync for Reply<'i>
impl<'i> Unpin for Reply<'i>
impl<'i> UnsafeUnpin for Reply<'i>
impl<'i> UnwindSafe for Reply<'i>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more