1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-10 18:10:56 +09:00

LibJS: Replace GlobalObject with VM in remaining AOs [Part 19/19]

This commit is contained in:
Linus Groh 2022-08-21 20:38:35 +01:00
parent 25849f8a6d
commit 56b2ae5ac0
Notes: sideshowbarker 2024-07-17 07:53:23 +09:00
46 changed files with 173 additions and 207 deletions

View file

@ -1133,7 +1133,6 @@ void Object::define_native_function(PropertyKey const& property_key, Function<Th
// 20.1.2.3.1 ObjectDefineProperties ( O, Properties ), https://tc39.es/ecma262/#sec-objectdefineproperties
ThrowCompletionOr<Object*> Object::define_properties(Value properties)
{
auto& global_object = this->global_object();
auto& vm = this->vm();
// 1. Let props be ? ToObject(Properties).
@ -1163,7 +1162,7 @@ ThrowCompletionOr<Object*> Object::define_properties(Value properties)
auto descriptor_object = TRY(props->get(property_key));
// ii. Let desc be ? ToPropertyDescriptor(descObj).
auto descriptor = TRY(to_property_descriptor(global_object, descriptor_object));
auto descriptor = TRY(to_property_descriptor(vm, descriptor_object));
// iii. Append the pair (a two element List) consisting of nextKey and desc to the end of descriptors.
descriptors.append({ property_key, descriptor });