Index: test/mjsunit/asm/asm-validation.js |
diff --git a/test/mjsunit/asm/asm-validation.js b/test/mjsunit/asm/asm-validation.js |
index 0c9e841fe94ad4b95ac0579b482cf5ed9b41ccb5..b2d701cc7e1ccf522a680d3208119a8bcc6eb336 100644 |
--- a/test/mjsunit/asm/asm-validation.js |
+++ b/test/mjsunit/asm/asm-validation.js |
@@ -344,6 +344,21 @@ function assertValidAsm(func) { |
assertEquals(4, m.foo(3)); |
})(); |
+(function TestBadFroundTrue() { |
+ function Module(stdlib) { |
+ "use asm"; |
+ var fround = stdlib.Math.fround; |
+ function foo() { |
+ var x = fround(true); |
+ return +x; |
+ } |
+ return { foo: foo }; |
+ } |
+ var m = Module(this); |
+ assertFalse(%IsAsmWasmCode(Module)); |
+ assertEquals(1, m.foo()); |
+})(); |
+ |
(function TestBadCase() { |
function Module() { |
"use asm"; |