diff options
author | Linus Groh <mail@linusgroh.de> | 2022-08-16 00:20:50 +0100 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2022-08-23 13:58:30 +0100 |
commit | e992a9f469a536b5a5442229a1adddd27deb1db9 (patch) | |
tree | 0fcfb0c3205530e9fd91d2cf8da315fb467e6d70 /Userland/Libraries/LibJS/Runtime/SymbolObject.cpp | |
parent | b99cc7d05039b9386538a581244be5af782c8d05 (diff) | |
download | serenity-e992a9f469a536b5a5442229a1adddd27deb1db9.zip |
LibJS+LibWeb: Replace GlobalObject with Realm in Heap::allocate<T>()
This is a continuation of the previous three commits.
Now that create() receives the allocating realm, we can simply forward
that to allocate(), which accounts for the majority of these changes.
Additionally, we can get rid of the realm_from_global_object() in one
place, with one more remaining in VM::throw_completion().
Diffstat (limited to 'Userland/Libraries/LibJS/Runtime/SymbolObject.cpp')
-rw-r--r-- | Userland/Libraries/LibJS/Runtime/SymbolObject.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibJS/Runtime/SymbolObject.cpp b/Userland/Libraries/LibJS/Runtime/SymbolObject.cpp index 08418fa0f9..61344a3b13 100644 --- a/Userland/Libraries/LibJS/Runtime/SymbolObject.cpp +++ b/Userland/Libraries/LibJS/Runtime/SymbolObject.cpp @@ -12,7 +12,7 @@ namespace JS { SymbolObject* SymbolObject::create(Realm& realm, Symbol& primitive_symbol) { - return realm.heap().allocate<SymbolObject>(realm.global_object(), primitive_symbol, *realm.global_object().symbol_prototype()); + return realm.heap().allocate<SymbolObject>(realm, primitive_symbol, *realm.global_object().symbol_prototype()); } SymbolObject::SymbolObject(Symbol& symbol, Object& prototype) |