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

This commit is contained in:
Linus Groh 2022-08-21 19:24:32 +01:00
commit 25849f8a6d
Notes: sideshowbarker 2024-07-17 07:53:28 +09:00
95 changed files with 536 additions and 677 deletions

View file

@ -40,10 +40,9 @@ ThrowCompletionOr<Value> BooleanConstructor::call()
ThrowCompletionOr<Object*> BooleanConstructor::construct(FunctionObject& new_target)
{
auto& vm = this->vm();
auto& global_object = this->global_object();
auto b = vm.argument(0).to_boolean();
return TRY(ordinary_create_from_constructor<BooleanObject>(global_object, new_target, &GlobalObject::boolean_prototype, b));
return TRY(ordinary_create_from_constructor<BooleanObject>(vm, new_target, &GlobalObject::boolean_prototype, b));
}
}