[r6rs-discuss] [Scheme-reports] Date and time arithmetic library proposal for R7RS large Scheme
alaric at snell-pym.org.uk
Mon Nov 29 06:48:20 EST 2010
On 11/28/10 02:17, Ray Dillinger wrote:
> Which "second" is preferable depends on the application.
Excellent summary of the situation, Ray!
As I see it, given that applications will want both seconds, the choice
here is really whether to provide both (look at the POSIX realtime
clocks API, which gives you separate "monotonic", "real time", "cpu
time", etc clocks), or to just provide one more "primitive" clock and
let the second clock be defined at a higher level.
Personally, I think "SI seconds elapsed since some epoch" is more
fundamental - that's useful even on tiny microcontrollers with no
real-time clock. That epoch might be system or process startup in such
cases. Time including leap seconds is, in my opinion, less fundamental
as it's all about human-chosen approximations to the motions of some
planet or other, to make it easier for them to decide when to sleep...
And as for the units: we can't measure the time exactly, so surely
inexact is quite appropriate? And even if we do develop an exact clock,
we have rationals to express that... So make the unit seconds!
More information about the r6rs-discuss