Time Libraries Rough Draft

Udo Stenzel u.stenzel at web.de
Mon Feb 14 03:59:47 EST 2005

Ashley Yakeley <ashley at semantic.org> schrieb am 11.02.05 21:39:42:
> The most obvious functions in Calendar are going to be these:
>   utcToCalendar :: TimeZone -> UTCTime -> CalendarTime
>   calendarToUTC :: TimeZone -> CalendarTime -> UTCTime

And what would you do with the "UTCTime", whatever that is?  You
can't do arithmetic on it, because that is full of surprises, not only
around leap seconds, but also around leap hours and days.  You
can only store it and read it back, but that can already be done with
the CalendarTime itself.

I think, the most useful operations are those that "roll" the calendar fields,
say to advance by a day (which is not always 24 hours long).  Converting a
CalendarTime to a number of seconds is just useless, the apparent 
simplification only introduces complications.


Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193

More information about the Libraries mailing list