1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 07:27:45 +00:00

LibJS: Remove unnecessary GlobalObject pointer from Environment

As it turns out, we didn't actually need this pointer. :^)
This commit is contained in:
Andreas Kling 2022-01-31 13:00:02 +01:00
parent 4a51165f5f
commit fc04465fa3
8 changed files with 17 additions and 32 deletions

View file

@ -26,7 +26,7 @@ void Realm::set_global_object(GlobalObject& global_object, Object* this_value)
// 5. Let newGlobalEnv be NewGlobalEnvironment(globalObj, thisValue).
// 6. Set realmRec.[[GlobalEnv]] to newGlobalEnv.
m_global_environment = global_object.heap().allocate<GlobalEnvironment>(global_object, global_object, *this_value);
m_global_environment = global_object.heap().allocate_without_global_object<GlobalEnvironment>(global_object, *this_value);
// 7. Return realmRec.
}