Function holochain_wasmer_guest::host_args [−][src]
pub fn host_args<O>(ptr: GuestPtr, len: Len) -> Result<O, GuestPtrLen> where
O: DeserializeOwned + Debug,
Expand description
Receive arguments from the host.
The guest sets the type O that the host needs to match.
If deserialization fails then a GuestPtr
to a WasmError::Deserialize
is returned.
The guest should immediately return an Err
back to the host.
The WasmError::Deserialize
enum contains the bytes that failed to deserialize so the host can
unambiguously provide debug information.