summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/closures/t020.js
blob: 30c8b463df8c9bb5bcf9021f724c14ac508e0e10 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
actual = '';
expected = '0,0,1,1,2,2,3,3,';

{ let f = function() {
    for (let x = 0; x < 4; ++x) {
      (function() {
	for (let y = 0; y < 2; ++y) {
	  appendToActual(x);
	}
      })()
	}
};
    f(0)
}


assertEq(actual, expected)