Enum wain_syntax_text::parser::ParseErrorKind
source · pub enum ParseErrorKind<'source> {
Show 16 variants
LexError(LexError<'source>),
UnexpectedToken {
got: Token<'source>,
expected: &'static str,
},
UnexpectedEndOfFile {
expected: &'static str,
},
UnexpectedKeyword(&'source str),
InvalidValType(&'source str),
MalformedUtf8Encoding,
MissingParen {
paren: char,
got: Option<Token<'source>>,
what: &'source str,
},
InvalidOperand {
insn: &'static str,
msg: &'static str,
},
NumberMustBePositive(NumBase, &'source str),
CannotParseNum {
reason: String,
ty: &'static str,
},
MultipleEntrypoints(Start<'source>, Start<'source>),
IdAlreadyDefined {
id: &'source str,
prev_idx: u32,
what: &'static str,
scope: &'static str,
},
ExpectEndOfFile {
token: Token<'source>,
after: &'static str,
},
ImportMustPrecedeOtherDefs {
what: &'static str,
},
InvalidAlignment(u32),
IdBoundToParam(&'source str),
}
Variants§
LexError(LexError<'source>)
UnexpectedToken
UnexpectedEndOfFile
UnexpectedKeyword(&'source str)
InvalidValType(&'source str)
MalformedUtf8Encoding
MissingParen
InvalidOperand
NumberMustBePositive(NumBase, &'source str)
CannotParseNum
MultipleEntrypoints(Start<'source>, Start<'source>)
IdAlreadyDefined
ExpectEndOfFile
ImportMustPrecedeOtherDefs
InvalidAlignment(u32)
IdBoundToParam(&'source str)
Auto Trait Implementations§
impl<'source> RefUnwindSafe for ParseErrorKind<'source>
impl<'source> Send for ParseErrorKind<'source>
impl<'source> Sync for ParseErrorKind<'source>
impl<'source> Unpin for ParseErrorKind<'source>
impl<'source> UnwindSafe for ParseErrorKind<'source>
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