[whatwg] Parsing RFC3339 constructs

Julian Reschke julian.reschke at gmx.de
Mon Apr 27 03:59:11 PDT 2009


Michael(tm) Smith wrote:
> Ian Hickson <ian at hixie.ch>, 2009-04-25 05:35 +0000:
> 
>> On Fri, 2 Jan 2009, Asbjørn Ulsberg wrote:
>>> Reading the spec, I have to wonder: Does HTML5 need to specify as much 
>>> as it does inline? Can't more of it be referenced to ISO 8601 or even 
>>> better; RFC 3339? I really fancy how Atom (RFC 4287) has defined date 
>>> constructs: <http://www.atompub.org/rfc4287.html#date.constructs> Does 
>>> not RFC 3339 defined date and time in a satisfactory manner to use 
>>> directly in HTML5?
>> The problem isn't so much the syntax definitions as the parsing 
>> definitions. We need very specific parsing rules; it's not clear that 
>> there is anything to refer to that does the job we need here.
> 
> It seems pretty clear that there isn't anything else to refer to
> for the date/time parsing rules -- but to me at least, specifying
> those rules seems orthogonal to specifying the date/time syntax,
> and I would think the syntax could just be defined by making
> reference to the productions[1] in RFC 3339 (instead of completely
> redefining them), while stating any exceptions.
> 
> [1] http://tools.ietf.org/html/rfc3339#section-5.6
> 
> I think the exceptions might just amount to:
> 
>   - the literal letters T and Z must be uppercase

Any technical reason why they have to?

>   - a year must be four or more digits, and must be greater that zero

"a year must be four or more digits" -- sounds like an alternative
format that an additional RFC, updating RFC 3339 could specify.

"must be greater that zero" -- that's not syntax :-)

So yes, I think referring to RFC 3339, even if it's just a narrative
mention, would be good.

Ian replied:
> I don't understand what that would gain us.

It would help people understand what the difference to RFC 3339 is.

BR, Julian




More information about the whatwg mailing list