Trait wasmer_runtime_core_fl::typed_func::WasmTypeList[][src]

pub trait WasmTypeList {
    type CStruct;
    type RetArray: AsMut<[u64]>;
    fn from_ret_array(array: Self::RetArray) -> Self;
fn empty_ret_array() -> Self::RetArray;
fn from_c_struct(c_struct: Self::CStruct) -> Self;
fn into_c_struct(self) -> Self::CStruct;
fn types() -> &'static [Type];
unsafe fn call<Rets>(
        self,
        f: NonNull<Func>,
        wasm: Wasm,
        ctx: *mut Ctx
    ) -> Result<Rets, RuntimeError>
    where
        Rets: WasmTypeList
; }
Expand description

Represents a list of WebAssembly values.

Associated Types

CStruct type.

Array of return values.

Required methods

Construct Self based on an array of returned values.

Generates an empty array that will hold the returned values of the WebAssembly function.

Transforms C values into Rust values.

Transforms Rust values into C values.

Get types of the current values.

This method is used to distribute the values onto a function, e.g. (1, 2).call(func, …). This form is unlikely to be used directly in the code, see the Func::call implementation.

Implementations on Foreign Types

Implementors