Enum janetrs::function::CallErrorKind
source · #[non_exhaustive]pub enum CallErrorKind {
Arity,
Run,
Yield,
}
Expand description
Kinds of errors of CallError
.
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.
Arity
Wrong number of parameters passed.
Run
Fail to run a JanetFunction
.
Yield
JanetFunction
yielded. That is not a problem per see, but some methods may
expect a JanetFunction
to return instead of yielding a value.
Trait Implementations§
source§impl Clone for CallErrorKind
impl Clone for CallErrorKind
source§fn clone(&self) -> CallErrorKind
fn clone(&self) -> CallErrorKind
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for CallErrorKind
impl Debug for CallErrorKind
source§impl Hash for CallErrorKind
impl Hash for CallErrorKind
source§impl Ord for CallErrorKind
impl Ord for CallErrorKind
source§fn cmp(&self, other: &CallErrorKind) -> Ordering
fn cmp(&self, other: &CallErrorKind) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for CallErrorKind
impl PartialEq for CallErrorKind
source§fn eq(&self, other: &CallErrorKind) -> bool
fn eq(&self, other: &CallErrorKind) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for CallErrorKind
impl PartialOrd for CallErrorKind
source§fn partial_cmp(&self, other: &CallErrorKind) -> Option<Ordering>
fn partial_cmp(&self, other: &CallErrorKind) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for CallErrorKind
impl Eq for CallErrorKind
impl StructuralPartialEq for CallErrorKind
Auto Trait Implementations§
impl Freeze for CallErrorKind
impl RefUnwindSafe for CallErrorKind
impl Send for CallErrorKind
impl Sync for CallErrorKind
impl Unpin for CallErrorKind
impl UnwindSafe for CallErrorKind
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