tor-browser

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

file_envChain_subscript.js (816B)


      1 /* This Source Code Form is subject to the terms of the Mozilla Public
      2 * License, v. 2.0. If a copy of the MPL was not distributed with this
      3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      4 
      5 var qualified = 10;
      6 unqualified = 20;
      7 let lexical = 30;
      8 this.prop = 40;
      9 
     10 const funcs = Cu.getJSTestingFunctions();
     11 const envs = [];
     12 let env = funcs.getInnerMostEnvironmentObject();
     13 while (env) {
     14  envs.push({
     15    type: funcs.getEnvironmentObjectType(env) || "*global*",
     16    qualified: !!Object.getOwnPropertyDescriptor(env, "qualified"),
     17    unqualified: !!Object.getOwnPropertyDescriptor(env, "unqualified"),
     18    lexical: !!Object.getOwnPropertyDescriptor(env, "lexical"),
     19    prop: !!Object.getOwnPropertyDescriptor(env, "prop"),
     20  });
     21 
     22  env = funcs.getEnclosingEnvironmentObject(env);
     23 }
     24 
     25 this.ENVS = envs;