Debian Codegraph @

js/src/tests/test262/language/eval-code/direct/global-env-rec-catch.js

raw
1 // Copyright (c) 2012 Ecma International. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3 /*---
4 es5id: 10.4.2-1-3
5 description: >
6 Direct call to eval has context set to local context (catch block)
7 ---*/
8
9 var __10_4_2_1_3 = "str";
10 function testcase() {
11 var __10_4_2_1_3 = "str1";
12 try {
13 throw "error";
14 }
15 catch (e) {
16 var __10_4_2_1_3 = "str2";
17 assert(eval("\'str2\' === __10_4_2_1_3"), 'direct eval');
18 }
19 }
20 testcase();
21
22 reportCompare(0, 0);