mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-13 13:02:28 +00:00
LibJS: Use narrower types in Temporal PlainDate/PlainDateTime/Calendar
These are bounds-checked during construction of PlainDate/PlainDateTime and as such theres no need to widen them in these internal AO calls.
This commit is contained in:
parent
c5c32ad274
commit
2c6bd3a61b
Notes:
sideshowbarker
2024-07-18 08:18:57 +09:00
Author: https://github.com/IdanHo
Commit: 2c6bd3a61b
Pull-request: https://github.com/SerenityOS/serenity/pull/9023
Reviewed-by: https://github.com/linusg ✅
11 changed files with 47 additions and 49 deletions
|
@ -53,11 +53,11 @@ PlainDate* date_from_fields(GlobalObject&, Object& calendar, Object& fields, Obj
|
|||
bool calendar_equals(GlobalObject&, Object& one, Object& two);
|
||||
bool is_iso_leap_year(i32 year);
|
||||
u16 iso_days_in_year(i32 year);
|
||||
i32 iso_days_in_month(i32 year, i32 month);
|
||||
u8 iso_days_in_month(i32 year, u8 month);
|
||||
u8 to_iso_day_of_week(i32 year, u8 month, u8 day);
|
||||
u16 to_iso_day_of_year(i32 year, u8 month, u8 day);
|
||||
u8 to_iso_week_of_year(i32 year, u8 month, u8 day);
|
||||
String build_iso_month_code(i32 month);
|
||||
String build_iso_month_code(u8 month);
|
||||
double resolve_iso_month(GlobalObject&, Object& fields);
|
||||
Optional<TemporalDate> iso_date_from_fields(GlobalObject&, Object& fields, Object& options);
|
||||
i32 iso_year(Object& temporal_object);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue