[][src]Struct boa::environment::function_environment_record::FunctionEnvironmentRecord

pub struct FunctionEnvironmentRecord {
    pub env_rec: HashMap<String, DeclerativeEnvironmentRecordBinding>,
    pub this_value: Value,
    pub this_binding_status: BindingStatus,
    pub function_object: Value,
    pub home_object: Value,
    pub new_target: Value,
    pub outer_env: Option<Environment>,
}

https://tc39.github.io/ecma262/#table-16

Fields

env_rec: HashMap<String, DeclerativeEnvironmentRecordBinding>this_value: Value

This is the this value used for this invocation of the function.

this_binding_status: BindingStatus

If the value is "lexical", this is an ArrowFunction and does not have a local this value.

function_object: Value

The function object whose invocation caused this Environment Record to be created.

home_object: Value

If the associated function has super property accesses and is not an ArrowFunction, [[HomeObject]] is the object that the function is bound to as a method. The default value for [[HomeObject]] is undefined.

new_target: Value

If this Environment Record was created by the [[Construct]] internal method, [[NewTarget]] is the value of the [[Construct]] newTarget parameter. Otherwise, its value is undefined.

outer_env: Option<Environment>

Reference to the outer environment to help with the scope chain Option type is needed as some environments can be created before we know what the outer env is

Methods

impl FunctionEnvironmentRecord[src]

pub fn bind_this_value(&mut self, value: Value)[src]

pub fn get_this_binding(&self) -> Value[src]

Trait Implementations

impl EnvironmentRecordTrait for FunctionEnvironmentRecord[src]

impl Drop for FunctionEnvironmentRecord[src]

impl Clone for FunctionEnvironmentRecord[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Trace for FunctionEnvironmentRecord[src]

impl Finalize for FunctionEnvironmentRecord[src]

fn finalize(&self)[src]

Auto Trait Implementations

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]