
17 May
2005
17 May
'05
12:07 p.m.
On Tue, 17 May 2005 00:27:55 -0700, Bulat Ziganshin
modificationTime :: Ptr CStat -> IO ClockTime modificationTime stat = do mtime <- st_mtime stat let realToInteger = round . realToFrac :: Real a => a -> Integer return (TOD (realToInteger (mtime :: CTime)) 0)
Eek, don't round time, truncate it. It doesn't become 10 o'clock until the minute hand moves all the way back to the twelve. The minute doesn't advance until the second hand moves all the way to the next minute. This is true for any level of precision with time. Dave