summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/defaultvalue-toString-is-noncallable-object-elem.js
blob: b5a28be554652e577b9e6008f4bdb6785f51b4a4 (plain)
1
2
3
4
var arr = ["foo", "bar"];
var obj = { toString: {}, valueOf: function() { return 1; } };
for (var i = 0; i < 25; i++)
  assertEq(arr[obj], "bar");