mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 11:49: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
Notes:
sideshowbarker
2024-07-18 04:11:25 +09:00
Author: https://github.com/linusg
Commit: 2b8d5696ab
Pull-request: https://github.com/SerenityOS/serenity/pull/9980
Reviewed-by: https://github.com/awesomekling ✅
8 changed files with 54 additions and 10 deletions
|
@ -22,9 +22,10 @@ Interpreter* Interpreter::current()
|
|||
return s_current;
|
||||
}
|
||||
|
||||
Interpreter::Interpreter(GlobalObject& global_object)
|
||||
Interpreter::Interpreter(GlobalObject& global_object, Realm& realm)
|
||||
: m_vm(global_object.vm())
|
||||
, m_global_object(global_object)
|
||||
, m_realm(realm)
|
||||
{
|
||||
VERIFY(!s_current);
|
||||
s_current = this;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue