pub enum GLLParseError<'a> {
UnexpectedByte {
pointer: usize,
expected: u8,
offender: u8,
},
TooLong {
pointer: usize,
offender: Terminal<'a>,
},
NoCandidates {
pointer: usize,
rule: String,
context: String,
},
ZeroWeights {
pointer: usize,
rule: String,
context: String,
},
}Expand description
Errors possible while GLL parsing.
Variants§
UnexpectedByte
Encountered an unexpected byte.
Fields
TooLong
Expected more bytes than found in the input string.
Fields
NoCandidates
All the alternatives to this rule failed the first_set check.
Fields
ZeroWeights
All the alternatives to this rule had a 0 weight.
Trait Implementations§
Source§impl<'a> Debug for GLLParseError<'a>
impl<'a> Debug for GLLParseError<'a>
Source§impl<'a> Display for GLLParseError<'a>
impl<'a> Display for GLLParseError<'a>
Source§impl<'a> Error for GLLParseError<'a>
impl<'a> Error for GLLParseError<'a>
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
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl<'a> From<GLLParseError<'a>> for GLLError<'a>
impl<'a> From<GLLParseError<'a>> for GLLError<'a>
Source§fn from(value: GLLParseError<'a>) -> Self
fn from(value: GLLParseError<'a>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<'a> Freeze for GLLParseError<'a>
impl<'a> RefUnwindSafe for GLLParseError<'a>
impl<'a> Send for GLLParseError<'a>
impl<'a> Sync for GLLParseError<'a>
impl<'a> Unpin for GLLParseError<'a>
impl<'a> UnsafeUnpin for GLLParseError<'a>
impl<'a> UnwindSafe for GLLParseError<'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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more