#[non_exhaustive]pub enum WasmError {
Show 17 variants
Io {
path: String,
message: String,
},
ModuleTooLarge {
size: usize,
limit: usize,
},
InvalidModule(String),
Instantiate(String),
MissingExport(String),
AbiVersion {
found: i32,
supported: i32,
},
Manifest(String),
DuplicateKind(String),
UnknownKind(String),
KindConflict(String),
FuelExhausted,
MemoryLimit,
Trap(String),
TooLarge {
what: &'static str,
size: usize,
limit: usize,
},
OutOfBounds {
ptr: u32,
len: u32,
},
InvalidOutput(String),
Internal(String),
}Expand description
Error loading or calling a guest module.
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.
Io
ModuleTooLarge
InvalidModule(String)
Instantiate(String)
MissingExport(String)
AbiVersion
Manifest(String)
DuplicateKind(String)
UnknownKind(String)
KindConflict(String)
FuelExhausted
MemoryLimit
Trap(String)
TooLarge
OutOfBounds
InvalidOutput(String)
Internal(String)
Implementations§
Trait Implementations§
impl Eq for WasmError
Source§impl Error for WasmError
impl Error for WasmError
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()
impl StructuralPartialEq for WasmError
Auto Trait Implementations§
impl Forget for WasmError
impl Freeze for WasmError
impl Move for WasmError
impl RefUnwindSafe for WasmError
impl Send for WasmError
impl Sync for WasmError
impl Unpin for WasmError
impl UnsafeUnpin for WasmError
impl UnwindSafe for WasmError
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.