1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/js/src/jit-test/tests/ion/bug820873.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,28 @@ 1.4 + 1.5 +var lfcode = new Array(); 1.6 +lfcode.push("3"); 1.7 +lfcode.push("with(evalcx('')) this.__defineGetter__('x', Function);"); 1.8 +lfcode.push("gczeal(2)"); 1.9 +lfcode.push("4"); 1.10 +lfcode.push("\ 1.11 + var log = '';\ 1.12 + for (var { m } = i = 0 ; ; i++) {\ 1.13 + log += x; \ 1.14 + if (x === 6)\ 1.15 + a.slow = true; if (i > 1000) break;\ 1.16 + }\ 1.17 +"); 1.18 +while (true) { 1.19 + var file = lfcode.shift(); if (file == undefined) { break; } 1.20 + loadFile(file) 1.21 +} 1.22 +function loadFile(lfVarx) { 1.23 + if (!isNaN(lfVarx)) { 1.24 + lfRunTypeId = parseInt(lfVarx); 1.25 + } else { 1.26 + switch (lfRunTypeId) { 1.27 + case 3: function newFunc(x) { new Function(x)(); }; newFunc(lfVarx); break; 1.28 + case 4: eval("(function() { " + lfVarx + " })();"); break; 1.29 + } 1.30 + } 1.31 +}