mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 16:47:44 +00:00
LibJS: Allocate a Realm next to GlobalObject in Interpreter::create()
Also pass a Realm reference to the Bytecode::Interpreter constructor, just like we pass the GlobalObject.
This commit is contained in:
parent
d9c3bafcd9
commit
2b8d5696ab
8 changed files with 54 additions and 10 deletions
|
@ -23,6 +23,8 @@ public:
|
|||
return vm.heap().allocate_without_global_object<Realm>();
|
||||
}
|
||||
|
||||
void set_global_object(GlobalObject&, Object* this_value = nullptr);
|
||||
|
||||
[[nodiscard]] GlobalObject& global_object() const { return *m_global_object; }
|
||||
[[nodiscard]] GlobalEnvironment& global_environment() const { return *m_global_environment; }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue