diff options
author | Alon Zakai <alonzakai@gmail.com> | 2016-08-28 10:33:09 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2016-09-07 09:55:56 -0700 |
commit | 28767f631cfdae86ff16ca112bc5b1855b1368c4 (patch) | |
tree | e7b1e1605c62fc8d588dd2735ac8610eb1b793df /src/js | |
parent | 42ad2cdbe5baa32dd1b0aea143a4e45f81e8b9b5 (diff) | |
download | binaryen-28767f631cfdae86ff16ca112bc5b1855b1368c4.tar.gz binaryen-28767f631cfdae86ff16ca112bc5b1855b1368c4.tar.bz2 binaryen-28767f631cfdae86ff16ca112bc5b1855b1368c4.zip |
import table
Diffstat (limited to 'src/js')
-rw-r--r-- | src/js/wasm.js-post.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/js/wasm.js-post.js b/src/js/wasm.js-post.js index dcffb1ee8..d691c22f2 100644 --- a/src/js/wasm.js-post.js +++ b/src/js/wasm.js-post.js @@ -274,10 +274,13 @@ function integrateWasmJS(Module) { global = fixImports(global); env = fixImports(env); - // import memory + // import memory and table if (!env['memory']) { env['memory'] = providedBuffer; } + if (!env['table']) { + env['table'] = new Array(1024); + } // try the methods. each should return the exports if it succeeded |