michael@0: actual = ''; michael@0: expected = '0,0,1,1,2,2,3,3,'; michael@0: michael@0: v = 0 michael@0: let( michael@0: f = function() { michael@0: for (let x = 0; x < 4; ++x) { michael@0: v >> x; michael@0: (function() { michael@0: for (let y = 0; y < 2; ++y) { michael@0: appendToActual(x) michael@0: } michael@0: })() michael@0: } michael@0: }) { (function() {})() michael@0: f(v) michael@0: } michael@0: michael@0: michael@0: assertEq(actual, expected)