1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 17:47:36 +00:00

LibJS: Implement the ToTemporalDate Abstract Operation

This is required by most Temporal.PlainDate.prototype methods.
This commit is contained in:
Idan Horowitz 2021-07-21 22:20:57 +03:00 committed by Linus Groh
parent 1e471e2e2f
commit cf78efaef5
7 changed files with 245 additions and 11 deletions

View file

@ -35,6 +35,7 @@ private:
};
PlainDate* create_temporal_date(GlobalObject&, i32 iso_year, i32 iso_month, i32 iso_day, Object& calendar, FunctionObject* new_target = nullptr);
PlainDate* to_temporal_date(GlobalObject&, Value item, Object* options = nullptr);
Optional<TemporalDate> regulate_iso_date(GlobalObject&, double year, double month, double day, String const& overflow);
bool is_valid_iso_date(i32 year, i32 month, i32 day);