Closed Bug 1858851 Opened 6 months ago Closed 6 months ago

Dashed dates with alphabetic month names and year > 9999 parse incorrectly

Categories

(Core :: JavaScript: Standard Library, defect, P3)

defect

Tracking

()

RESOLVED FIXED
121 Branch
Tracking Status
firefox121 --- fixed

People

(Reporter: vinny.diehl, Assigned: vinny.diehl)

References

(Blocks 1 open bug)

Details

(Keywords: dev-doc-needed, parity-chrome, parity-safari)

Attachments

(1 file)

The year is parsed as a negative.

> eshost -te 'new Date("01-Jan-10000").toString()'
Engine Result
JavaScriptCore Sat Jan 01 10000 00:00:00 GMT-0700 (Mountain Standard Time)
SpiderMonkey Sat Jan 01 -10000 00:00:00 GMT-0728 (Mountain Standard Time)
V8 Sat Jan 01 10000 00:00:00 GMT-0700 (Mountain Standard Time)

This presents similarly to bug 1617562, because the format is being rejected by TryParseDashedDatePrefix; some trivial adjustments to make it accept 5- and 6-digit years should fix this.

Blocks: 1274354
Summary: Dashed dates with year > 9999 parse incorrectly → Dashed dates with alphabetic month names and year > 9999 parse incorrectly
Assignee: nobody → vinny.diehl
Status: NEW → ASSIGNED
Priority: -- → P3
Pushed by arai_a@mac.com:
https://hg.mozilla.org/integration/autoland/rev/00c1813123fd
Fix parsing for dashed dates with alphabetic month and year > 9999 r=arai

This was overflowing s on opt builds, fixed.

Flags: needinfo?(vinny.diehl)
Pushed by arai_a@mac.com:
https://hg.mozilla.org/integration/autoland/rev/36a87a643270
Fix parsing for dashed dates with alphabetic month and year > 9999 r=arai
See Also: → 1860716
Status: ASSIGNED → RESOLVED
Closed: 6 months ago
Resolution: --- → FIXED
Target Milestone: --- → 121 Branch
See Also: → 1557650
Keywords: dev-doc-needed
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: