bug1331058.js (554B)
1 function foo(o, trigger) { 2 bar = function() { return o.getY(); }; 3 if (trigger) 4 assertEq(bar(), undefined); 5 return 1; 6 } 7 function O(o, trigger) { 8 this.a1 = 1; 9 this.a2 = 2; 10 this.a3 = 3; 11 this.a4 = 4; 12 this.x = foo(this, trigger); 13 } 14 O.prototype.getY = function() { 15 return this.x; 16 } 17 function test() { 18 with(this) {}; // No Ion. 19 var arr = []; 20 for (var i=0; i<100; i++) 21 arr.push(new O({y: i}, false)); 22 23 for (var i=0; i<100; i++) 24 bar(); 25 26 for (var i=0; i<300; i++) 27 arr.push(new O({y: i}, true)); 28 } 29 test();