1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/js/src/jit-test/tests/basic/bug642154.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,16 @@ 1.4 +assertEq(Math.pow(1, undefined), NaN); 1.5 +assertEq(Math.pow(1, null), 1); 1.6 +assertEq(Math.pow(1, true), 1); 1.7 +assertEq(Math.pow(1, false), 1); 1.8 +assertEq(Math.pow(1, 0), 1); 1.9 +assertEq(Math.pow(1, -0), 1); 1.10 +assertEq(Math.pow(1, NaN), NaN); 1.11 +assertEq(Math.pow(1, {}), NaN); 1.12 +assertEq(Math.pow(1, {valueOf: function() { return undefined; }}), NaN); 1.13 + 1.14 +x = 2.2; 1.15 +assertEq(Math.pow(x - 1.2, undefined), NaN); 1.16 + 1.17 +var y; 1.18 +assertEq(Math.pow(1, y), NaN); 1.19 +