pub enum Error<'a> {
ErrorKind {
input: &'a BStr,
kind: ErrorKind,
},
ErrorWithContexts(Vec<ParseTypeContext<'a>>),
}
Expand description
Variants§
Trait Implementations§
Source§impl<'a> ContextError<&'a [u8]> for Error<'a>
impl<'a> ContextError<&'a [u8]> for Error<'a>
Source§impl<'a, I: Into<&'a [u8]>, E> FromExternalError<I, E> for Error<'a>
impl<'a, I: Into<&'a [u8]>, E> FromExternalError<I, E> for Error<'a>
Source§fn from_external_error(input: I, kind: ErrorKind, _e: E) -> Self
fn from_external_error(input: I, kind: ErrorKind, _e: E) -> Self
Creates a new error from an input position, an ErrorKind indicating the
wrapping parser, and an external error
Source§impl<'a> ParseError<&'a [u8]> for Error<'a>
impl<'a> ParseError<&'a [u8]> for Error<'a>
Source§fn from_error_kind(input: &'a [u8], kind: ErrorKind) -> Self
fn from_error_kind(input: &'a [u8], kind: ErrorKind) -> Self
Creates an error from the input position and an ErrorKind
Source§fn append(input: &'a [u8], kind: ErrorKind, other: Self) -> Self
fn append(input: &'a [u8], kind: ErrorKind, other: Self) -> Self
Combines an existing error with a new one created from the input
position and an ErrorKind. This is useful when backtracking
through a parse tree, accumulating error context on the way
impl<'a> Eq for Error<'a>
impl<'a> StructuralPartialEq for Error<'a>
Auto Trait Implementations§
impl<'a> Freeze for Error<'a>
impl<'a> RefUnwindSafe for Error<'a>
impl<'a> Send for Error<'a>
impl<'a> Sync for Error<'a>
impl<'a> Unpin for Error<'a>
impl<'a> UnwindSafe for Error<'a>
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