blob: c6934b2c9b6a716dfe1b86c548e3c9f892e4d31d [file] [log] [blame]
//@ skip if $model == "Apple Watch Series 3" # added by mark-jsc-stress-test.py
function foo(string) {
var result = ["", ""];
for (var i = 0; i < 1000000; ++i)
result[i & 1] = string[i & 1];
return result;
}
var result = foo("x");
if (result[0] != "x")
throw "Bad result[0]: " + result[0];
if (typeof result[1] != "undefined")
throw "Bad result[1]: " + result[1];