#[non_exhaustive]pub enum ExecutionError {
BoolNoArithmetic,
Environment {
source: Error,
},
NilValue,
NoBoolean {
value: Arc<str>,
},
NoComparison,
NoInteger {
value: Arc<str>,
},
NoNumber {
value: Arc<str>,
},
StackOverflow,
OnlyAdd,
Unreachable {
file: Arc<str>,
line: u32,
},
}Expand description
Things that may go wrong during execution of a compiled script.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
BoolNoArithmetic
No arithemetic with boolean for now.
Environment
Passthrough environment errors.
NilValue
Nil does not allow anything.
NoBoolean
Expected Boolean, got something else.
NoComparison
Comparisons (greater, less) only with numeric values.
NoInteger
Expected Integer, got something else.
NoNumber
Expected a numerical value, got something else.
StackOverflow
Stack overflow.
OnlyAdd
Strings only allow additions.
Unreachable
This code line never should have been reached.
Trait Implementations§
Source§impl Debug for ExecutionError
impl Debug for ExecutionError
Source§impl Display for ExecutionError
impl Display for ExecutionError
Source§impl Error for ExecutionError
Currently the default implementation is sufficient.
impl Error for ExecutionError
Currently the default implementation is sufficient.
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 From<Error> for ExecutionError
impl From<Error> for ExecutionError
Source§impl From<ExecutionError> for Error
impl From<ExecutionError> for Error
Source§fn from(source: ExecutionError) -> Self
fn from(source: ExecutionError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ExecutionError
impl RefUnwindSafe for ExecutionError
impl Send for ExecutionError
impl Sync for ExecutionError
impl Unpin for ExecutionError
impl UnwindSafe for ExecutionError
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