1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:08:11 +00:00

LibJS: Use null-prototype objects in a few more places in Temporal

This is a normative change in the Temporal spec.

See: 334479f
This commit is contained in:
Linus Groh 2022-06-27 23:29:11 +01:00
parent 3720f4bd8f
commit ca85e157e8
2 changed files with 6 additions and 6 deletions

View file

@ -742,8 +742,8 @@ ThrowCompletionOr<Object*> merge_largest_unit_option(GlobalObject& global_object
{
auto& vm = global_object.vm();
// 1. Let merged be OrdinaryObjectCreate(%Object.prototype%).
auto* merged = Object::create(global_object, global_object.object_prototype());
// 1. Let merged be OrdinaryObjectCreate(null).
auto* merged = Object::create(global_object, nullptr);
// 2. Let keys be ? EnumerableOwnPropertyNames(options, key).
auto keys = TRY(options.enumerable_own_property_names(Object::PropertyKind::Key));
@ -1768,8 +1768,8 @@ ThrowCompletionOr<Object*> prepare_temporal_fields(GlobalObject& global_object,
{
auto& vm = global_object.vm();
// 1. Let result be OrdinaryObjectCreate(%Object.prototype%).
auto* result = Object::create(global_object, global_object.object_prototype());
// 1. Let result be OrdinaryObjectCreate(null).
auto* result = Object::create(global_object, nullptr);
VERIFY(result);
// 2. Let any be false.