fn new_global_environment(global: Value, this_value: Value) -> Gc<GcCell<GlobalEnvironmentRecord>> {
    let obj_rec = ObjectEnvironmentRecord {
        bindings: global,
        outer_env: None,
        /// Object Environment Records created for with statements (13.11)
        /// can provide their binding object as an implicit this value for use in function calls.
        /// The capability is controlled by a withEnvironment Boolean value that is associated
        /// with each object Environment Record. By default, the value of withEnvironment is false
        /// for any object Environment Record.
        with_environment: false,
    };

    let dcl_rec = DeclarativeEnvironmentRecord {
        env_rec: FxHashMap::default(),
        outer_env: None,
    };

    Gc::new(GcCell::new(GlobalEnvironmentRecord {
        object_record: obj_rec,
        global_this_binding: this_value,
        declarative_record: dcl_rec,
        var_names: FxHashSet::default(),
    }))
}
// Similar to new_global_environment in lexical_environment, except we need to return a GlobalEnvirionment
Similar to new_global_environment in lexical_environment, except we need to return a GlobalEnvirionment
Similar to new_global_environment in lexical_environment except we need to return a GlobalEnvirionment
fn new_global_environment(global: Value, this_value: Value) -> Gc<GcCell<GlobalEnvironmentRecord>> {
    let obj_rec = ObjectEnvironmentRecord {
        bindings: global,
        outer_env: None,
        /// Object Environment Records created for with statements (13.11)
        /// can provide their binding object as an implicit this value for use in function calls.
        /// The capability is controlled by a withEnvironment Boolean value that is associated
        /// with each object Environment Record. By default, the value of withEnvironment is false
        /// for any object Environment Record.
        with_environment: false,
    };
    let dcl_rec = DeclarativeEnvironmentRecord {
        env_rec: FxHashMap::default(),
        outer_env: None,
    };
    Gc::new(GcCell::new(GlobalEnvironmentRecord {
        object_record: obj_rec,
        global_this_binding: this_value,
        declarative_record: dcl_rec,
        var_names: FxHashSet::default(),
    }))
}
fn new_global_environment ( global : Value , this_value : Value ) -> Gc < GcCell < GlobalEnvironmentRecord > > { let obj_rec = ObjectEnvironmentRecord { bindings : global , outer_env : None , /// Object Environment Records created for with statements (13.11) /// can provide their binding object as an implicit this value for use in function calls. /// The capability is controlled by a withEnvironment Boolean value that is associated /// with each object Environment Record. By default, the value of withEnvironment is false /// for any object Environment Record. with_environment : false , } ; let dcl_rec = DeclarativeEnvironmentRecord { env_rec : FxHashMap :: default ( ) , outer_env : None , } ; Gc :: new ( GcCell :: new ( GlobalEnvironmentRecord { object_record : obj_rec , global_this_binding : this_value , declarative_record : dcl_rec , var_names : FxHashSet :: default ( ) , } ) ) }
Similar to new_global_environment in lexical_environment, except we need to return a GlobalEnvirionment
Similar to new_global_environment in lexical_environment except we need to return a GlobalEnvirionment
global
Value
this_value
Value