Claus Reinke wrote:
While you're looking at the code for time, Ashley, I've got a question about its relation to old-time: shouldn't System.Time have a DEPRECATED pragma, pointing to time? The comments and package name say old-time is deprecated in favour of time.
I looked into this; it's not quite that simple. System.Time exports ClockTime, which is still used in System.Directory.getModificationTime. So in order to properly deprecate System.Time, we have to supply an alternative to System.Directory.getModificationTime, which would introduce a dependency on the time package, and directory is currently a core package.
Thanks for checking, Simon. But wouldn't that simply mean replacing old-time with time in the corelibs, keeping old-time around for one or two releases only to get the deprecation message out? Perhaps time could even provide a compat module for the transition period, so that old-time could be dropped immediately, while current old-time clients transition from the compat module to proper time modules.
I don't think it's straightforward to implement System.Time in terms of Data.Time, so we really have to bring in time. Also, we have to replace System.Directory.getModificationTime (I suppose it should return UTCTime?), and hence we'll need a compat version of directory... or call the new function something different. Cheers, Simon