Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4725)

Unified Diff: test/mjsunit/wasm/table.js

Issue 2630553002: [wasm] Enforce that function bodies end with the \"end\" opcode. (Closed)
Patch Set: Collapse some tests together Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/mjsunit/wasm/indirect-tables.js ('k') | test/mjsunit/wasm/wasm-module-builder.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/wasm/table.js
diff --git a/test/mjsunit/wasm/table.js b/test/mjsunit/wasm/table.js
index 2eca796af2cc912e45b95dddd519abbc3a7b9b57..d2b0dcdee6c6d197181eb767f1e3136dbf575b64 100644
--- a/test/mjsunit/wasm/table.js
+++ b/test/mjsunit/wasm/table.js
@@ -152,7 +152,7 @@ function assertTableIsValid(table) {
(function TestSet() {
let builder = new WasmModuleBuilder;
- builder.addExport("wasm", builder.addFunction("", kSig_v_v));
+ builder.addExport("wasm", builder.addFunction("", kSig_v_v).addBody([]));
builder.addExport("host", builder.addImport("test", "f", kSig_v_v));
let {wasm, host} = builder.instantiate({test: {f() {}}}).exports;
@@ -200,7 +200,7 @@ function assertTableIsValid(table) {
(function TestIndexing() {
let builder = new WasmModuleBuilder;
- builder.addExport("wasm", builder.addFunction("", kSig_v_v));
+ builder.addExport("wasm", builder.addFunction("", kSig_v_v).addBody([]));
builder.addExport("host", builder.addImport("test", "f", kSig_v_v));
let {wasm, host} = builder.instantiate({test: {f() {}}}).exports;
@@ -223,7 +223,7 @@ function assertTableIsValid(table) {
(function TestGrow() {
let builder = new WasmModuleBuilder;
- builder.addExport("wasm", builder.addFunction("", kSig_v_v));
+ builder.addExport("wasm", builder.addFunction("", kSig_v_v).addBody([]));
builder.addExport("host", builder.addImport("test", "f", kSig_v_v));
let {wasm, host} = builder.instantiate({test: {f() {}}}).exports;
« no previous file with comments | « test/mjsunit/wasm/indirect-tables.js ('k') | test/mjsunit/wasm/wasm-module-builder.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698