mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:57:45 +00:00
LibJS: Implement Temporal.PlainTime.prototype[@@toStringTag]
This commit is contained in:
parent
ae4bf8fc32
commit
64b44c7f30
2 changed files with 8 additions and 0 deletions
|
@ -18,6 +18,11 @@ PlainTimePrototype::PlainTimePrototype(GlobalObject& global_object)
|
||||||
void PlainTimePrototype::initialize(GlobalObject& global_object)
|
void PlainTimePrototype::initialize(GlobalObject& global_object)
|
||||||
{
|
{
|
||||||
Object::initialize(global_object);
|
Object::initialize(global_object);
|
||||||
|
|
||||||
|
auto& vm = this->vm();
|
||||||
|
|
||||||
|
// 4.3.2 Temporal.PlainTime.prototype[ @@toStringTag ], https://tc39.es/proposal-temporal/#sec-temporal.plaintime.prototype-@@tostringtag
|
||||||
|
define_direct_property(*vm.well_known_symbol_to_string_tag(), js_string(vm.heap(), "Temporal.PlainTime"), Attribute::Configurable);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,3 @@
|
||||||
|
test("basic functionality", () => {
|
||||||
|
expect(Temporal.PlainTime.prototype[Symbol.toStringTag]).toBe("Temporal.PlainTime");
|
||||||
|
});
|
Loading…
Add table
Add a link
Reference in a new issue