MCPcopy
hub / github.com/Pradumnasaraf/DevOps / receiveInstance

Function receiveInstance

docs/webassembly/files/apps/hello-world/hello.js:713–727  ·  view source on GitHub ↗

@param {WebAssembly.Module=} module

(instance, module)

Source from the content-addressed store, hash-verified

711 // performing other necessary setup
712 /** @param {WebAssembly.Module=} module*/
713 function receiveInstance(instance, module) {
714 wasmExports = instance.exports;
715
716
717
718 wasmMemory = wasmExports['memory'];
719
720 assert(wasmMemory, 'memory not found in wasm exports');
721 updateMemoryViews();
722
723 addOnInit(wasmExports['__wasm_call_ctors']);
724
725 removeRunDependency('wasm-instantiate');
726 return wasmExports;
727 }
728 // wait for the pthread pool (if any)
729 addRunDependency('wasm-instantiate');
730

Callers 1

Calls 4

assertFunction · 0.85
updateMemoryViewsFunction · 0.85
addOnInitFunction · 0.85
removeRunDependencyFunction · 0.85

Tested by

no test coverage detected