[−][src]Function wasmer_vm::catch_traps
pub unsafe fn catch_traps<F>(
vmctx: VMFunctionEnvironment,
closure: F
) -> Result<(), Trap> where
F: FnMut(),
Catches any wasm traps that happen within the execution of closure
,
returning them as a Result
.
Safety
Highly unsafe since closure
won't have any destructors run.