diff options
-rw-r--r-- | src/wasm/wasm-s-parser.cpp | 2 | ||||
-rw-r--r-- | test/imported_memory.wast | 1 | ||||
-rw-r--r-- | test/imported_memory.wast.fromBinary | 1 | ||||
-rw-r--r-- | test/imported_memory.wast.fromBinary.noDebugInfo | 1 | ||||
-rw-r--r-- | test/imported_memory_growth.wast | 1 | ||||
-rw-r--r-- | test/imported_memory_growth.wast.fromBinary | 1 | ||||
-rw-r--r-- | test/imported_memory_growth.wast.fromBinary.noDebugInfo | 1 |
7 files changed, 7 insertions, 1 deletions
diff --git a/src/wasm/wasm-s-parser.cpp b/src/wasm/wasm-s-parser.cpp index 5898cc252..3fcb85c6b 100644 --- a/src/wasm/wasm-s-parser.cpp +++ b/src/wasm/wasm-s-parser.cpp @@ -1573,7 +1573,7 @@ void SExpressionWasmBuilder::parseImport(Element& s) { if (j < inner.size() - 1) { wasm.table.max = atoi(inner[j++]->c_str()); } else { - wasm.table.max = wasm.table.initial; + wasm.table.max = Table::kMaxSize; } // ends with the table element type } else if (im->kind == ExternalKind::Memory) { diff --git a/test/imported_memory.wast b/test/imported_memory.wast index fb3c45f5a..790ffbbfa 100644 --- a/test/imported_memory.wast +++ b/test/imported_memory.wast @@ -1,3 +1,4 @@ (module (import "env" "memory" (memory $0 256 256)) + (import "env" "table" (table 256 256 anyfunc)) ) diff --git a/test/imported_memory.wast.fromBinary b/test/imported_memory.wast.fromBinary index bcbd85473..5df005bc1 100644 --- a/test/imported_memory.wast.fromBinary +++ b/test/imported_memory.wast.fromBinary @@ -1,4 +1,5 @@ (module (import "env" "memory" (memory $0 256 256)) + (import "env" "table" (table 256 256 anyfunc)) ) diff --git a/test/imported_memory.wast.fromBinary.noDebugInfo b/test/imported_memory.wast.fromBinary.noDebugInfo index bcbd85473..5df005bc1 100644 --- a/test/imported_memory.wast.fromBinary.noDebugInfo +++ b/test/imported_memory.wast.fromBinary.noDebugInfo @@ -1,4 +1,5 @@ (module (import "env" "memory" (memory $0 256 256)) + (import "env" "table" (table 256 256 anyfunc)) ) diff --git a/test/imported_memory_growth.wast b/test/imported_memory_growth.wast index d13b95853..a6e99fe85 100644 --- a/test/imported_memory_growth.wast +++ b/test/imported_memory_growth.wast @@ -1,3 +1,4 @@ (module (import "env" "memory" (memory $0 256)) + (import "env" "table" (table 256 anyfunc)) ) diff --git a/test/imported_memory_growth.wast.fromBinary b/test/imported_memory_growth.wast.fromBinary index 426313d7f..821aba207 100644 --- a/test/imported_memory_growth.wast.fromBinary +++ b/test/imported_memory_growth.wast.fromBinary @@ -1,4 +1,5 @@ (module (import "env" "memory" (memory $0 256)) + (import "env" "table" (table 256 anyfunc)) ) diff --git a/test/imported_memory_growth.wast.fromBinary.noDebugInfo b/test/imported_memory_growth.wast.fromBinary.noDebugInfo index 426313d7f..821aba207 100644 --- a/test/imported_memory_growth.wast.fromBinary.noDebugInfo +++ b/test/imported_memory_growth.wast.fromBinary.noDebugInfo @@ -1,4 +1,5 @@ (module (import "env" "memory" (memory $0 256)) + (import "env" "table" (table 256 anyfunc)) ) |