blob: 16fdc9366b4c9fa23218506db86edb9c9f21e421 [file] [log] [blame]
function foo(arg) {
try {
return new Array(arg);
} catch (e) {
return "error42";
}
}
noInline(foo);
for (var i = 0; i < 100000; ++i) {
var result = foo(1);
if (result.length != 1)
throw "Error: bad result: " + result;
}
var result = foo(-1);
if (result != "error42")
throw "Error: bad result at end: " + result;