michael@0: this.name = "outer"; michael@0: michael@0: var sb = evalcx(''); michael@0: sb.name = "inner"; michael@0: sb.parent = this; michael@0: michael@0: function f() { michael@0: assertEq(this.name, "outer"); michael@0: } michael@0: michael@0: evalcx('with(this) { ff = parent.f; }; (function() { eval(""); for(var i=0; i<10; i++) { ff() } })()', sb);