MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / into_boxed_dyn_core_error

Function into_boxed_dyn_core_error

crates/core/src/error/vtable.rs:136–146  ·  view source on GitHub ↗
(
    error: OwnedPtr<DynError>,
)

Source from the content-addressed store, hash-verified

134}
135
136unsafe fn into_boxed_dyn_core_error<E>(
137 error: OwnedPtr<DynError>,
138) -> Result<Box<dyn core::error::Error + Send + Sync + 'static>, OutOfMemory>
139where
140 E: ErrorExt,
141{
142 let error = error.cast::<ConcreteError<E>>();
143 // Safety: implied by all vtable functions' safety contract.
144 let error = unsafe { error.into_box() };
145 error.error.ext_into_boxed_dyn_core_error()
146}
147
148unsafe fn drop_and_deallocate<E>(error: OwnedPtr<DynError>)
149where

Callers

nothing calls this directly

Calls 2

into_boxMethod · 0.80

Tested by

no test coverage detected