Struct parser_combinators::ParseError
[−]
[src]
pub struct ParseError<P: Positioner> { pub position: P::Position, pub errors: Vec<Error<P>>, }
Struct which hold information about an error that occured at a specific position.
Can hold multiple instances of Error
if more that one error occured at the position.
Fields
position: P::Position
The position where the error occured
errors: Vec<Error<P>>
A vector containing specific information on what errors occured at position
Methods
impl<P: Positioner> ParseError<P>
[src]
fn new(position: P::Position, error: Error<P>) -> ParseError<P>
fn empty(position: P::Position) -> ParseError<P>
fn from_errors(position: P::Position, errors: Vec<Error<P>>) -> ParseError<P>
fn end_of_input(position: P::Position) -> ParseError<P>
fn add_message<S>(&mut self, message: S) where
S: Into<Info<P>>,
S: Into<Info<P>>,
fn add_error(&mut self, message: Error<P>)
fn set_expected(&mut self, message: Info<P>)
fn merge(self, other: ParseError<P>) -> ParseError<P>
Trait Implementations
impl<P: Debug + Positioner> Debug for ParseError<P> where
P::Position: Debug,
[src]
P::Position: Debug,
impl<P: PartialEq + Positioner> PartialEq for ParseError<P> where
P::Position: PartialEq,
[src]
P::Position: PartialEq,
fn eq(&self, __arg_0: &ParseError<P>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &ParseError<P>) -> bool
This method tests for !=
.
impl<P> StdError for ParseError<P> where
P: Positioner + Display + Debug + Any,
P::Position: Display + Debug + Any,
[src]
P: Positioner + Display + Debug + Any,
P::Position: Display + Debug + Any,
fn description(&self) -> &str
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
1.0.0
The lower-level cause of this error, if any. Read more
impl<P: Positioner + Display> Display for ParseError<P> where
P::Position: Display,
[src]
P::Position: Display,