#[no_mangle]
pub unsafe extern "C" fn wasm_func_new(
store: &mut wasm_store_t,
ty: &wasm_functype_t,
callback: wasm_func_callback_t,
) -> Box<wasm_func_t>
Expand description
Creates a new wasm_func_t
of type wasm_functype_t
for the wasm_store_t
.
Calls the given wasm_func_callback_t
when calling the returned wasm_func_t
.
Wraps Func::new
.
§Safety
It is the caller’s responsibility not to alias the wasm_functype_t
with its underlying, internal WasmStoreRef
.