diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/unit.asm.js | 5 | ||||
-rw-r--r-- | test/unit.wast | 16 |
2 files changed, 21 insertions, 0 deletions
diff --git a/test/unit.asm.js b/test/unit.asm.js index 2b599d99a..db14f721b 100644 --- a/test/unit.asm.js +++ b/test/unit.asm.js @@ -18,9 +18,14 @@ function () { function doubleCompares(x, y) { x = +x; y = +y; + if (x > 0.0) return 0.0; if (x < y) return +x; return +y; } + function intOps() { + var x = 0; + return !x; + } function z() { } diff --git a/test/unit.wast b/test/unit.wast index 9e4b19eb4..72e124b41 100644 --- a/test/unit.wast +++ b/test/unit.wast @@ -54,6 +54,15 @@ (func $doubleCompares (param $x f64) (param $y f64) (result f64) (block $topmost (if + (f64.gt + (get_local $x) + (f64.const 0) + ) + (break $topmost + (f64.const 0) + ) + ) + (if (f64.lt (get_local $x) (get_local $y) @@ -67,6 +76,13 @@ ) ) ) + (func $intOps (result i32) + (local $x i32) + (i32.eq + (get_local $x) + (i32.const 0) + ) + ) (func $z (nop) ) |