Closed
Bug 1999917
Opened 2 months ago
Closed 1 day ago
No formatted output for large dates when using Chinese/Dangi calendars
Categories
(Core :: JavaScript: Internationalization API, defect, P3)
Core
JavaScript: Internationalization API
Tracking
()
RESOLVED
FIXED
149 Branch
| Tracking | Status | |
|---|---|---|
| firefox149 | --- | fixed |
People
(Reporter: anba, Assigned: anba)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
js> new Intl.DateTimeFormat("en-u-ca-chinese", {timeZone:"UTC"}).format(new Date("+100000-01-01T00:00:00.000Z"))
"/"
Returning "/" indicates there's some issue with ICU.
| Assignee | ||
Comment 1•2 months ago
|
||
This is an issue in ICU4C's computeMonthInfo function:
computeMonthInfogets called withgyear=100000anddays=35804722.- solsticeAfter is computed as
35805412. days=35804722 < solsticeAfter=35805412, so solsticeBefore is computed fromgyear-1 = 99999. The computed value issolsticeBefore = 35805047.- That means
days=35804722 < solsticeBefore=35805047, so this check fails andU_ILLEGAL_ARGUMENT_ERRORis returned.
Updating to ICU4X 2.1.1 (bug 1997048) should allow to remove the fallback code in ICU4XChineseBasedCalendar, which should fix this bug.
Depends on: 1997048
Updated•2 months ago
|
| Assignee | ||
Comment 3•8 days ago
|
||
We no longer need the fallback code after the upgrade to ICU4X 2.1.1, because
ICU4X can now handle all supported years.
Pushed by andre.bargull@gmail.com:
https://github.com/mozilla-firefox/firefox/commit/818473254269
https://hg.mozilla.org/integration/autoland/rev/359bd42b605d
Remove no longer needed ICU4C calendar fallback code. r=spidermonkey-reviewers,dminor
Updated•1 day ago
|
Component: JavaScript: Standard Library → JavaScript: Internationalization API
Comment 5•1 day ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 1 day ago
status-firefox149:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 149 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•