()
| 1770 | } |
| 1771 | __name(getWasmImports, "getWasmImports"); |
| 1772 | async function createWasm() { |
| 1773 | function receiveInstance(instance2, module2) { |
| 1774 | wasmExports = instance2.exports; |
| 1775 | wasmExports = relocateExports(wasmExports, 1024); |
| 1776 | var metadata2 = getDylinkMetadata(module2); |
| 1777 | if (metadata2.neededDynlibs) { |
| 1778 | dynamicLibraries = metadata2.neededDynlibs.concat(dynamicLibraries); |
| 1779 | } |
| 1780 | mergeLibSymbols(wasmExports, "main"); |
| 1781 | LDSO.init(); |
| 1782 | loadDylibs(); |
| 1783 | __RELOC_FUNCS__.push(wasmExports["__wasm_apply_data_relocs"]); |
| 1784 | assignWasmExports(wasmExports); |
| 1785 | return wasmExports; |
| 1786 | } |
| 1787 | __name(receiveInstance, "receiveInstance"); |
| 1788 | function receiveInstantiationResult(result2) { |
| 1789 | return receiveInstance(result2["instance"], result2["module"]); |
| 1790 | } |
| 1791 | __name(receiveInstantiationResult, "receiveInstantiationResult"); |
| 1792 | var info2 = getWasmImports(); |
| 1793 | if (Module["instantiateWasm"]) { |
| 1794 | return new Promise((resolve, reject) => { |
| 1795 | Module["instantiateWasm"](info2, (mod, inst) => { |
| 1796 | resolve(receiveInstance(mod, inst)); |
| 1797 | }); |
| 1798 | }); |
| 1799 | } |
| 1800 | wasmBinaryFile ??= findWasmBinary(); |
| 1801 | var result = await instantiateAsync(wasmBinary, wasmBinaryFile, info2); |
| 1802 | var exports = receiveInstantiationResult(result); |
| 1803 | return exports; |
| 1804 | } |
| 1805 | __name(createWasm, "createWasm"); |
| 1806 | class ExitStatus { |
| 1807 | static { |
no test coverage detected