summaryrefslogtreecommitdiff
path: root/test/wasm2js.asserts.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2019-04-22 14:46:42 -0700
committerGitHub <noreply@github.com>2019-04-22 14:46:42 -0700
commit711a22c65f28029ae0ca2d31a0cd6f8be9b953c7 (patch)
tree26b2db972bf4c4a2bf8041e07609cc0dd07a7eb5 /test/wasm2js.asserts.js
parentff710e63eaed7cf8fbf3042843f6243597da49be (diff)
downloadbinaryen-711a22c65f28029ae0ca2d31a0cd6f8be9b953c7.tar.gz
binaryen-711a22c65f28029ae0ca2d31a0cd6f8be9b953c7.tar.bz2
binaryen-711a22c65f28029ae0ca2d31a0cd6f8be9b953c7.zip
wasm2js: get rid of some non-flat code assumptions (#2036)
We run flatten there, which lets us simplify things a lot. Turns out that for assertions we didn't run it, which is why we still needed the old non-flat code paths. This adds flatten there and removes that old code and assumptions.
Diffstat (limited to 'test/wasm2js.asserts.js')
-rw-r--r--test/wasm2js.asserts.js4
1 files changed, 1 insertions, 3 deletions
diff --git a/test/wasm2js.asserts.js b/test/wasm2js.asserts.js
index 3ab4b1d08..3f0fb6709 100644
--- a/test/wasm2js.asserts.js
+++ b/test/wasm2js.asserts.js
@@ -79,10 +79,8 @@ function asmFunc0(global, env, buffer) {
const memasmFunc0 = new ArrayBuffer(65536);
const retasmFunc0 = asmFunc0({Math,Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array,NaN,Infinity}, {abort:function() { throw new Error('abort'); }},memasmFunc0);
function check1() {
- var wasm2js_i32$0 = 0;
retasmFunc0.empty();
- wasm2js_i32$0 = 1;
- return wasm2js_i32$0 | 0;
+ return 1 | 0;
}
if (!check1()) throw 'assertion failed: ( assert_return ( call empty ) )';