Enum wasmtime_runtime::Trap
source · [−]pub enum Trap {
User(Error),
Jit {
pc: usize,
backtrace: Backtrace,
},
Wasm {
trap_code: TrapCode,
backtrace: Backtrace,
},
OOM {
backtrace: Backtrace,
},
}Expand description
Stores trace message with backtrace.
Variants
User(Error)
A user-raised trap through raise_user_trap.
Jit
Fields
pc: usizeThe program counter in JIT code where this trap happened.
backtrace: BacktraceNative stack backtrace at the time the trap occurred
A trap raised from jit code
Wasm
Fields
trap_code: TrapCodeCode of the trap.
backtrace: BacktraceNative stack backtrace at the time the trap occurred
A trap raised from a wasm libcall
OOM
Fields
backtrace: BacktraceNative stack backtrace at the time the OOM occurred
A trap indicating that the runtime was unable to allocate sufficient memory.
Implementations
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Trap
impl Send for Trap
impl Sync for Trap
impl Unpin for Trap
impl !UnwindSafe for Trap
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more