[Python-Dev] datetime +/- scalars (int, long, float)?
Jack Jansen
Jack.Jansen@oratrix.com
Tue, 5 Mar 2002 22:32:04 +0100
On dinsdag, maart 5, 2002, at 08:25 , Guido van Rossum wrote:
> I think I want to introduce a new concept, closely related to local
> time, that I'll dub "naive time" for now. In naive time, there is no
> timezone and there is no DST. To compensate for DST, you have to
> manually change the clock, which is an action outside the system,
> unknown to the system, and irrelevant to the working of the system.
> Ditto to change time zones.
This sounds like an absolutely brilliant idea! And I think that
if you keep the equivalent of the tm_isdst bit you can get all
the conversions working too. And it fits the model: I have a
naive tm_isdst bit in my head on that one night per year (if it
hasn't been lost in partying yet:-).
Hmm, and possibly you want a function discontinuity(t1, t2) that
will return 0 normally but something else (a value in seconds?
Then it could even be used for leap seconds by the real
die-hards) if there's a time discontinuity between t1 and t2.
--
- Jack Jansen <Jack.Jansen@oratrix.com>
http://www.cwi.nl/~jack -
- If I can't dance I don't want to be part of your revolution --
Emma Goldman -