michael@0: actual = ''; michael@0: expected = '101,'; michael@0: michael@0: function looper(f) { michael@0: for (var i = 0; i < 10; ++i) { michael@0: for (var j = 0; j < 10; ++j) { michael@0: f(); michael@0: } michael@0: } michael@0: } michael@0: michael@0: function tester() { michael@0: var x = 1; michael@0: looper(function() { ++x; }); michael@0: return x; michael@0: } michael@0: michael@0: appendToActual(tester()); michael@0: michael@0: michael@0: assertEq(actual, expected)