Enum wasmtime_runtime::TrapReason 
source · Expand description
Enumeration of different methods of raising a trap.
Variants§
User
Fields
A user-raised trap through raise_user_trap.
Jit(usize)
A trap raised from Cranelift-generated code with the pc listed of where the trap came from.
Wasm(Trap)
A trap raised from a wasm libcall
Implementations§
source§impl TrapReason
 
impl TrapReason
sourcepub fn user_without_backtrace(error: Error) -> Self
 
pub fn user_without_backtrace(error: Error) -> Self
Create a new TrapReason::User that does not have a backtrace yet.
sourcepub fn user_with_backtrace(error: Error) -> Self
 
pub fn user_with_backtrace(error: Error) -> Self
Create a new TrapReason::User that already has a backtrace.