pub enum LexError {
UnterminatedQuote,
InvalidEscape(char),
NulByte,
TooLong {
max: usize,
actual: usize,
},
UnsupportedMetacharacter(char),
}Expand description
Why a line could not be tokenized.
Variants§
UnterminatedQuote
A ' or " was opened but never closed.
InvalidEscape(char)
A \ inside a double-quoted string preceded an unsupported character.
NulByte
The input contained a NUL byte.
TooLong
The input exceeded MAX_LINE_LEN, checked before tokenizing.
UnsupportedMetacharacter(char)
An unquoted shell metacharacter appeared outside a quoted token.
Trait Implementations§
impl Eq for LexError
Source§impl From<LexError> for ParseError
impl From<LexError> for ParseError
impl StructuralPartialEq for LexError
Auto Trait Implementations§
impl Freeze for LexError
impl RefUnwindSafe for LexError
impl Send for LexError
impl Sync for LexError
impl Unpin for LexError
impl UnsafeUnpin for LexError
impl UnwindSafe for LexError
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