summaryrefslogtreecommitdiff
path: root/src/asm2wasm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/asm2wasm.h')
-rw-r--r--src/asm2wasm.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/asm2wasm.h b/src/asm2wasm.h
index 306a953a7..e27c5d9e2 100644
--- a/src/asm2wasm.h
+++ b/src/asm2wasm.h
@@ -832,6 +832,14 @@ void Asm2WasmBuilder::processAsm(Ref ast) {
memoryImport->base = MEMORY;
memoryImport->kind = Import::Memory;
wasm.addImport(memoryImport.release());
+
+ // import table
+ auto tableImport = make_unique<Import>();
+ tableImport->name = TABLE;
+ tableImport->module = ENV;
+ tableImport->base = TABLE;
+ tableImport->kind = Import::Table;
+ wasm.addImport(tableImport.release());
#endif
#if 0 // enable asm2wasm i64 optimizations when browsers have consistent i64 support in wasm