[−][src]Enum ketos::exec::ExecError
Represents an error generated while executing bytecode.
Variants
Error in arity to function call
Fields of ArityError
Attempt to compare with a NaN
Float
value.
CannotCompare(&'static str)
Type does not support ordered comparison
CannotDefine(Name)
Attempt to redefine a name in master scope
Attempt to divide by a number equal to zero.
DuplicateField(Name)
Duplicate field name in struct definition
DuplicateKeyword(Name)
Duplicate keyword argument to function
DuplicateStructDef(Name)
Duplicate struct definition
No such field name in struct
Type error assigning value to field
Fields of FieldTypeError
Error in format
call
Fields of FormatError
fmt: Box<str>
Supplied format string
span: Span
Span within format string
err: FormatError
Formatting error produced
InvalidClosureValue(u32)
Invalid index into closure values
InvalidConst(u32)
Invalid const index
Invalid (zero) depth value to Quote
, Quasiquote
, or Comma
instruction
InvalidJump(u32)
Invalid jump label
Slice indices out of order
InvalidStack(u32)
Invalid stack index
InvalidSystemFn(u32)
Invalid system function
MissingArgCount(Name)
CallSys
instruction for system function which requires argument count
Attempt to construct a Struct
without the given field
NameError(Name)
Attempt to lookup a name that did not exist in scope.
NotCharBoundary(usize)
Attempt to slice a string not along UTF-8 code point boundaries.
Odd number of parameters when keyword-value pairs expected
OutOfBounds(usize)
Attempt to access an element in a list that is out of bounds.
Integer overflow during certain arithmetic operations.
Code called panic
StructDefError(Name)
Struct definition not found
Operation performed on unexpected type
Fields of TypeError
Function received a value of incorrect type
Fields of StructMismatch
Attempt to operate on two values of incompatible types
Fields of TypeMismatch
Unexpected end in bytecode
UnrecognizedKeyword(Name)
Unrecognized keyword passed to function
UnrecognizedOpCode(u8)
Unrecognized opcode
Methods
impl ExecError
[src]
pub fn expected(expected: &'static str, v: &Value) -> ExecError
[src]
Convenience function to return a TypeError
value when expected
type is expected, but some other type of value is found.
pub fn expected_field(
struct_name: Name,
field: Name,
expected: Name,
v: &Value
) -> ExecError
[src]
struct_name: Name,
field: Name,
expected: Name,
v: &Value
) -> ExecError
Convenience function to return a FieldTypeError
value when a struct
field of the incorrect type is received.
Trait Implementations
impl Debug for ExecError
[src]
impl Display for ExecError
[src]
impl Error for ExecError
[src]
fn description(&self) -> &str
[src]
fn cause(&self) -> Option<&dyn Error>
1.0.0[src]
fn source(&self) -> Option<&(dyn Error + 'static)>
1.30.0[src]
fn backtrace(&self) -> Option<&Backtrace>
[src]
impl From<ExecError> for Error
[src]
impl NameDisplay for ExecError
[src]
Auto Trait Implementations
impl !RefUnwindSafe for ExecError
impl !Send for ExecError
impl !Sync for ExecError
impl Unpin for ExecError
impl !UnwindSafe for ExecError
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,