pub unsafe fn allocate_single_memory_instance(
    req: InstanceAllocationRequest<'_>,
    memory: Memory
) -> Result<InstanceHandle, InstantiationError>
Expand description

Allocate an instance containing a single memory.

In order to import a Memory into a WebAssembly instance, Wasmtime requires that memory to exist in its own instance. Here we bring to life such a “Frankenstein” instance with the only purpose of exporting a Memory.