polywrap_wasm.instance module

This module contains the imports of the Wasm wrapper module.

polywrap_wasm.instance.create_instance(store: Store, module: bytes, state: State, invoker: Invoker | None) Instance[source]

Create a Wasm instance for a Wasm module.

Parameters:
  • store (Store) – The Wasm store.

  • module (bytes) – The Wasm module.

  • state (State) – The state of the Wasm module.

  • invoker (Optional[Invoker]) – The invoker to use for subinvocations.

Returns:

The Wasm instance.

Return type:

Instance