blob: 903932022775860ff3b8fb6661cbfb3ca6b35d1c [file] [log] [blame]
function foo() {
return /(f)(o)(o)/.exec("foo");
}
noInline(foo);
for (var i = 0; i < 10000; ++i) {
var result = foo();
if (result.length != 4)
throw "Error: bad result: " + result;
if (result[0] != "foo")
throw "Error: bad result: " + result;
if (result[1] != "f")
throw "Error: bad result: " + result;
if (result[2] != "o")
throw "Error: bad result: " + result;
if (result[3] != "o")
throw "Error: bad result: " + result;
}