[
Lists Home |
Date Index |
Thread Index
]
Hi Dare,
>> The algorithm in the W3C XML Schema Datatypes Recommendation adds
>> the year/month component first (which would give 2005-02-29), then
>> "pins" the result of that to give a legal date (i.e. 2005-02-28),
>> and then adds the day and time components of the duration (to give
>> the final answer of 2005-03-01).
>
> Which Astonishes me (as in Principle of Least Astonishment). I would
> have expected a year after 2-29 to be 3-1.
>
> Did I misread John's email? 2005-03-01 is 3-1 isn't it?
Yes, but he said he would have expected *[one] year* after 2-29 to be
3-1, i.e. for 2004-02-29 + P1Y to be 2005-03-01. Whereas the W3C XML
Schema Rec. algorithm says that 2004-02-29 + P1Y is 2005-02-28.
Cheers,
Jeni
---
Jeni Tennison
http://www.jenitennison.com/
|