mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 10:08:10 +00:00
LibJS: Add ObjectEnvironmentRecord.[[IsWithEnvironment]] field
This is true for environments created by `with` statements, and false for other (global) object environments. Also add the WithBaseObject abstract operation while we're here.
This commit is contained in:
parent
3f8857cd21
commit
0cd65b55bd
5 changed files with 22 additions and 7 deletions
|
@ -16,7 +16,7 @@ GlobalEnvironmentRecord::GlobalEnvironmentRecord(GlobalObject& global_object)
|
|||
: EnvironmentRecord(nullptr)
|
||||
, m_global_object(global_object)
|
||||
{
|
||||
m_object_record = global_object.heap().allocate<ObjectEnvironmentRecord>(global_object, global_object, nullptr);
|
||||
m_object_record = global_object.heap().allocate<ObjectEnvironmentRecord>(global_object, global_object, ObjectEnvironmentRecord::IsWithEnvironment::No, nullptr);
|
||||
m_declarative_record = global_object.heap().allocate<DeclarativeEnvironmentRecord>(global_object);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue