tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

global-env-rec-catch.js (636B)


      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    Indirect call to eval has context set to global context (catch
      7    block)
      8 ---*/
      9 
     10 var __10_4_2_1_3 = "str";
     11 function testcase() {
     12            var _eval = eval;
     13            var __10_4_2_1_3 = "str1";
     14            try {
     15                throw "error";
     16            }
     17            catch (e) {
     18                var __10_4_2_1_3 = "str2";
     19                assert(_eval("\'str\' === __10_4_2_1_3"), 'indirect eval');
     20            }
     21    }
     22 testcase();
     23 
     24 reportCompare(0, 0);