Trait wasmer::IntoResult

source ·
pub trait IntoResult<T>
where T: WasmTypeList,
{ type Error: Error + Sync + Send + 'static; // Required method fn into_result(self) -> Result<T, Self::Error>; }
Expand description

The IntoResult trait turns a WasmTypeList into a Result<WasmTypeList, Self::Error>.

It is mostly used to turn result values of a Wasm function call into a Result.

Required Associated Types§

source

type Error: Error + Sync + Send + 'static

The error type for this trait.

Required Methods§

source

fn into_result(self) -> Result<T, Self::Error>

Transforms Self into a Result.

Implementations on Foreign Types§

source§

impl<T, E> IntoResult<T> for Result<T, E>
where T: WasmTypeList, E: Error + Sync + Send + 'static,

§

type Error = E

source§

fn into_result(self) -> Self

Implementors§

source§

impl<T> IntoResult<T> for T
where T: WasmTypeList,