michael@0: // Copyright 2009 the Sputnik authors. All rights reserved. michael@0: // This code is governed by the BSD license found in the LICENSE file. michael@0: michael@0: /** michael@0: * The scope chain is initialised to contain the same objects, michael@0: * in the same order, as the calling context's scope chain michael@0: * michael@0: * @path ch10/10.4/10.4.2/S10.4.2_A1.1_T7.js michael@0: * @description eval within global execution context michael@0: */ michael@0: michael@0: var i; michael@0: var j; michael@0: str1 = ''; michael@0: str2 = ''; michael@0: x = 1; michael@0: michael@0: for(i in this){ michael@0: str1+=i; michael@0: } michael@0: michael@0: eval('for(j in this){\nstr2+=j;\n}'); michael@0: michael@0: if(!(str1 === str2)){ michael@0: $ERROR("#1: scope chain must contain same objects in the same order as the calling context"); michael@0: } michael@0: michael@0: var y = 2; michael@0: