pub enum ErrorKind<E = u32> {
Show 59 variants
Custom(E),
Tag,
MapRes,
MapOpt,
Alt,
IsNot,
IsA,
SeparatedList,
SeparatedNonEmptyList,
Many0,
Many1,
ManyTill,
Count,
TakeUntilAndConsume,
TakeUntil,
TakeUntilEitherAndConsume,
TakeUntilEither,
LengthValue,
TagClosure,
Alpha,
Digit,
HexDigit,
OctDigit,
AlphaNumeric,
Space,
MultiSpace,
LengthValueFn,
Eof,
ExprOpt,
ExprRes,
CondReduce,
Switch,
TagBits,
OneOf,
NoneOf,
Char,
CrLf,
RegexpMatch,
RegexpMatches,
RegexpFind,
RegexpCapture,
RegexpCaptures,
TakeWhile1,
Complete,
Fix,
Escaped,
EscapedTransform,
TagStr,
IsNotStr,
IsAStr,
TakeWhile1Str,
NonEmpty,
ManyMN,
TakeUntilAndConsumeStr,
TakeUntilStr,
Not,
Permutation,
Verify,
TakeTill1,
}
Expand description
A Result of any parsing action.
If the input is invalid, an IResult::Error
will be returned.
Note that incomplete data is not considered invalid,
and so will not return an error, but rather a IResult::Incomplete(_)
.
indicates which parser returned an error
Variants§
Custom(E)
Tag
MapRes
MapOpt
Alt
IsNot
IsA
SeparatedList
SeparatedNonEmptyList
Many0
Many1
ManyTill
Count
TakeUntilAndConsume
TakeUntil
TakeUntilEitherAndConsume
TakeUntilEither
LengthValue
TagClosure
Alpha
Digit
HexDigit
OctDigit
AlphaNumeric
Space
MultiSpace
LengthValueFn
Eof
ExprOpt
ExprRes
CondReduce
Switch
TagBits
OneOf
NoneOf
Char
CrLf
RegexpMatch
RegexpMatches
RegexpFind
RegexpCapture
RegexpCaptures
TakeWhile1
Complete
Fix
Escaped
EscapedTransform
TagStr
IsNotStr
IsAStr
TakeWhile1Str
NonEmpty
ManyMN
TakeUntilAndConsumeStr
TakeUntilStr
Not
Permutation
Verify
TakeTill1
Implementations§
Source§impl<E> ErrorKind<E>
impl<E> ErrorKind<E>
pub fn description(&self) -> &str
Sourcepub fn into_error_kind(self) -> ErrorKind<E>
pub fn into_error_kind(self) -> ErrorKind<E>
Convert Err into an ErrorKind.
This allows application code to use ErrorKind and stay independent from the verbose-errors
features activation.
Trait Implementations§
Source§impl<E> Error for ErrorKind<E>
impl<E> Error for ErrorKind<E>
Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
impl<E> Eq for ErrorKind<E>where
E: Eq,
impl<E> StructuralPartialEq for ErrorKind<E>
Auto Trait Implementations§
impl<E> Freeze for ErrorKind<E>where
E: Freeze,
impl<E> RefUnwindSafe for ErrorKind<E>where
E: RefUnwindSafe,
impl<E> Send for ErrorKind<E>where
E: Send,
impl<E> Sync for ErrorKind<E>where
E: Sync,
impl<E> Unpin for ErrorKind<E>where
E: Unpin,
impl<E> UnwindSafe for ErrorKind<E>where
E: UnwindSafe,
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