monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Monotone-devel] dates in monotone


From: Markus Wanner
Subject: [Monotone-devel] dates in monotone
Date: Thu, 16 Oct 2008 16:07:31 +0200
User-agent: Thunderbird 2.0.0.16 (X11/20080916)

Hi,

for the CVS import branch I needed to compare dates. Up until now,
monotone parses the given date strings, but still used strings
internally to represent dates.

In nvm.dates I've switched to using unsigned 64bit integers to represent
dates internally (as seconds since the Unix epoch). That required adding
a method similar to the mktime() system call, which translates year,
month, day, hour, min, sec values into such a timestamp. As the existing
function, which does the reverse, it does not care about leap seconds,
but only handles leap days correctly.

While that's find and dandy, I'm still wondering why we (uhm.. Zack)
have implemented gmtime() from scratch. The comments tell something
about systems not using the Unix epoch. But which system? Are the
mktime() and gmtime() system functions really that unusable for portable
software?

Regards

Markus Wanner




reply via email to

[Prev in Thread] Current Thread [Next in Thread]