Enum rhai::LexError [−][src]
#[non_exhaustive] pub enum LexError { UnexpectedInput(String), UnterminatedString, StringTooLong(usize), MalformedEscapeSequence(String), MalformedNumber(String), MalformedChar(String), MalformedIdentifier(String), ImproperSymbol(String, String), }
Expand description
(INTERNALS) Error encountered when tokenizing the script text.
Exported under the internals
feature only.
Volatile Data Structure
This type is volatile and may change.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
UnexpectedInput(String)
An unexpected symbol is encountered when tokenizing the script text.
A string literal is not terminated before a new-line or EOF.
StringTooLong(usize)
An identifier is in an invalid format.
MalformedEscapeSequence(String)
An string/character/numeric escape sequence is in an invalid format.
MalformedNumber(String)
An numeric literal is in an invalid format.
MalformedChar(String)
An character literal is in an invalid format.
MalformedIdentifier(String)
An identifier is in an invalid format.
Bad symbol encountered when tokenizing the script text.
Implementations
impl LexError
[src]
impl LexError
[src]pub fn into_err(self, pos: Position) -> ParseError
[src]
pub fn into_err(self, pos: Position) -> ParseError
[src]Convert a LexError
into a ParseError
.
Trait Implementations
impl Error for LexError
[src]
impl Error for LexError
[src]fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]
fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]The lower-level source of this error, if any. Read more
fn backtrace(&self) -> Option<&Backtrace>
[src]
fn backtrace(&self) -> Option<&Backtrace>
[src]backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
fn description(&self) -> &str
1.0.0[src]
fn description(&self) -> &str
1.0.0[src]use the Display impl or to_string()
impl From<LexError> for ParseErrorType
[src]
impl From<LexError> for ParseErrorType
[src]impl Eq for LexError
[src]
impl StructuralEq for LexError
[src]
impl StructuralPartialEq for LexError
[src]
Auto Trait Implementations
impl RefUnwindSafe for LexError
impl Send for LexError
impl Sync for LexError
impl Unpin for LexError
impl UnwindSafe for LexError
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> CallHasher for T where
T: Hash + ?Sized,
[src]
impl<T> CallHasher for T where
T: Hash + ?Sized,
[src]impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more