« Bugzilla Issues Index
#267 — Date toString should specify result for "invalid dates"
- bug_id:
267
- creation_ts:
2012-02-14 10:35:00 -0800
- short_desc:
Date toString should specify result for "invalid dates"
- delta_ts:
2012-02-14 10:35:59 -0800
- product:
ECMA-262, Editions 5 and 5.1
- component:
technical content
- version:
Edition 5.1
- rep_platform:
All
- op_sys:
All
- bug_status:
CONFIRMED
- priority:
Normal
- bug_severity:
enhancement
- blocked:
268
- everconfirmed:
true
- reporter:
Allen Wirfs-Brock
- assigned_to:
Allen Wirfs-Brock
- commentid:
642
- comment_count:
0
- who:
Allen Wirfs-Brock
- bug_when:
2012-02-14 10:35:13 -0800
15.9.5.2 says the result of Date.prototype.toString is an implementation-defined string. However, all browser implementations appear to return the string "Invalid Date" for Date objects whose time value is NaN.
This result should be specified.
Open issue: Do implementations every localize this string? Is that acceptable or should the literal text "Invalid Date" be required.