Enum twig::error::RuntimeError [] [src]

pub enum RuntimeError {
    InvalidArgumentCount {
        defined: usize,
        given: usize,
    },
    ObjectHasNoProperty(String),
    ObjectHasNoMethod(String),
    ObjectPropertyIsNotMethod(String),
    ObjectMethodIsNotProperty(String),
    ObjectMethodArgumentMismatch {
        name: String,
        defined: u16,
        given: u16,
    },
    ImpossibleCast {
        target: CastTarget,
        reason: CastError,
    },
}

Runtime error message.

Variants

InvalidArgumentCount

Callable invoked with argument count that does not match defined count.

Fields

defined
given
ObjectHasNoProperty

Tried to access object property that does not exist.

ObjectHasNoMethod

Tried to access object method that does not exist.

ObjectPropertyIsNotMethod

Tried to access object property but it was a method.

ObjectMethodIsNotProperty

Tried to access object method but it was a property.

ObjectMethodArgumentMismatch

Tried to call object method with wrong argument count.

Fields

name
defined
given
ImpossibleCast

Value casting error.

Fields

target
reason

Methods

impl RuntimeError

fn at(self, stack_trace: Vec<TraceEntry>) -> TracedRuntimeError

Trait Implementations

impl Display for RuntimeError

fn fmt(&self, f: &mut Formatter) -> Result

Derived Implementations

impl Debug for RuntimeError

fn fmt(&self, __arg_0: &mut Formatter) -> Result

impl Clone for RuntimeError

fn clone(&self) -> RuntimeError

fn clone_from(&mut self, source: &Self)