Wed, 31 Dec 2014 07:53:36 +0100
Correct small whitespace inconsistency, lost while renaming variables.
1 // Copyright 2009 the Sputnik authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
4 /**
5 * Function's scope chain is started when it is declared
6 *
7 * @path ch13/13.2/S13.2.2_A19_T6.js
8 * @description Function is declared in the "object->do-while" scope, then the object is deleted and another object with the same name is declared
9 */
11 var a = 1;
13 var __obj = {a:2};
15 with (__obj)
16 {
17 do {
18 var __func = function()
19 {
20 return a;
21 }
22 } while(0);
23 }
25 delete __obj;
27 var __obj = {a:3};
29 with (__obj)
30 {
31 result = __func();
32 }
34 //////////////////////////////////////////////////////////////////////////////
35 //CHECK#1
36 if (result !== 2) {
37 $ERROR('#1: result === 2. Actual: result ==='+result);
38 }
39 //
40 //////////////////////////////////////////////////////////////////////////////