[−][src]Enum rhai::EvalAltResult
Evaluation result.
All wrapped Position
values represent the location in the script where the error occurs.
Currently, EvalAltResult
is neither Send
nor Sync
. Turn on the sync
feature to make it Send + Sync
.
Variants
ErrorParsing(Box<ParseError>)
Syntax error.
Error reading from a script file. Wrapped value is the path of the script file.
Never appears under the no_std
feature.
Call to an unknown function. Wrapped value is the name of the function.
Function call has incorrect number of arguments. Wrapped values are the name of the function, the number of parameters required and the actual number of arguments passed.
Non-boolean operand encountered for boolean operator. Wrapped value is the operator.
ErrorCharMismatch(Position)
Non-character value encountered where a character is required.
Array access out-of-bounds. Wrapped values are the current number of elements in the array and the index number.
String indexing out-of-bounds. Wrapped values are the current number of characters in the string and the index number.
Trying to index into a type that is not an array, an object map, or a string.
ErrorNumericIndexExpr(Position)
Trying to index into an array or string with an index that is not i64
.
ErrorStringIndexExpr(Position)
Trying to index into a map with an index that is not String
.
ErrorInExpr(Position)
Invalid arguments for in
operator.
ErrorLogicGuard(Position)
The guard expression in an if
or while
statement does not return a boolean value.
ErrorFor(Position)
The for
statement encounters a type that is not an iterator.
Usage of an unknown variable. Wrapped value is the name of the variable.
ErrorAssignmentToUnknownLHS(Position)
Assignment to an inappropriate LHS (left-hand-side) expression.
Assignment to a constant variable.
Returned type is not the same as the required output type. Wrapped value is the type of the actual result.
Inappropriate member access.
Arithmetic error encountered. Wrapped value is the error message.
ErrorStackOverflow(Position)
Call stack over maximum limit.
Run-time error encountered. Wrapped value is the error message.
Breaking out of loops - not an error if within a loop.
The wrapped value, if true, means breaking clean out of the loop (i.e. a break
statement).
The wrapped value, if false, means breaking the current context (i.e. a continue
statement).
Not an error: Value returned from a script via the return
keyword.
Wrapped value is the result value.
Methods
impl EvalAltResult
[src]
Trait Implementations
impl Debug for EvalAltResult
[src]
impl Display for EvalAltResult
[src]
impl Error for EvalAltResult
[src]
Auto Trait Implementations
impl !RefUnwindSafe for EvalAltResult
impl !Send for EvalAltResult
impl !Sync for EvalAltResult
impl Unpin for EvalAltResult
impl !UnwindSafe for EvalAltResult
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,