>-----Original Message----- >From: Zefram [mailto:[email protected]] >Sent: 24 April 2012 18:14 >To: [email protected] >Cc: Carl Vincent >Subject: Re: ISO 8601 Format YYYY-MM-DDThh:mm:ss.sss[+-]hhmm > >Thomas Klausner wrote: >>Though I'm not sure why (beeing not familiar with the spec), my patch >>was rejected. > >ISO 8601 implies (but does not explicitly state) that you must be >consistent within a single expression about whether you use the >hyphen and colon separators ("extended format"). With the time of >day expressed as "10:39:00.000", the UT offset should be expressed as >"+00:00", not "+0000". So an ISO 8601 parser is justified in rejecting >"10:39:00.000+0000".
Since this is only an implicit requirement of the standard - and I don't have access to the full standard text, and I can't find reference to this elsewhere - is it necessary for its support to be excluded from the library? I can't see a case where the lack of a colon in the time offset introduces ambiguity in the parsing. It may be poor style, but it's not necessarily broken. Since these formats are out there in use, it would be better for the module to parse them if it's not going to introduce errors. I'm not suggesting we produce imperfectly styled ISO dates. What happened to the idea of being accommodating in what you accept and strict in what you produce? Carl -- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Carl Vincent http://www.netskills.ac.uk/ (URL) Systems Manager 0191 222 5003 (voice) Netskills, Newcastle University 0191 222 5001 (fax) Netskills is a JISC Advance service Training - Development - Research - Innovation
