Struct wasmer_runtime_fl::DynFunc [−][src]
pub struct DynFunc<'a> { /* fields omitted */ }
Expand description
A representation of an exported WebAssembly function.
Implementations
Call an exported WebAssembly function safely.
Pass arguments by wrapping each one in the Value
enum.
The returned values are also each wrapped in a Value
.
Note:
This returns CallResult<Vec<Value>>
in order to support
the future multi-value returns WebAssembly feature.
Usage:
instance .dyn_func("foo")? .call(&[])?;
Trait Implementations
Auto Trait Implementations
impl<'a> !RefUnwindSafe for DynFunc<'a>
impl<'a> !UnwindSafe for DynFunc<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more
type Output = T
type Output = T
Should always be Self
Attempt to lookup self in the given table.
pub fn wrap_self(
self,
storage: &mut TableStorage,
index: u32
) -> Result<(), TableAccessError>
pub fn wrap_self(
self,
storage: &mut TableStorage,
index: u32
) -> Result<(), TableAccessError>
Wrap value to be stored in a table.