The Tor Browser
/ file comparison
Search:
summary
shortlog
changelog
graph
tags
bookmarks
branches
files
help
file
revisions
annotate
diff
comparison
raw
comparison: js/src/jit-test/tests/for-of/array-holes-1.js
js/src/jit-test/tests/for-of/array-holes-1.js
changeset 0
6474c204b198
equal
deleted
inserted
replaced
-1:000000000000
0:78490b5a197f
1
// for-of does not skip Array holes. The value at a hole is undefined.
2
3
var a = [0, , 2, 3];
4
var log = [];
5
for (var x of a) {
6
assertEq(x, a[log.length]);
7
log.push(x);
8
}
9
assertEq(log[1], undefined);
10
assertEq(log.join(), "0,,2,3");