[Top][All Lists]

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

Re: Exposing subsecond precision in current-seconds

From: John Cowan
Subject: Re: Exposing subsecond precision in current-seconds
Date: Mon, 27 Apr 2020 14:44:59 -0400

Such a procedure is in SRFI 170: (posix-time).

As I pointed out in #chicken, gettimeofday() has been obsolete since 2008, per Posix, which recommends clock_gettime(), which is precise (of course not accurate) to nanoseconds and has been part of Posix since 1997.  Not that getttimeofday() is likely to go away, but more precision is better than less.'

On Windows 8 and later, you can use GetSystemTimePreciseAsFileTime, which returns the number of 100-nanosecond clunks since the beginning of the year 1601 proleptic UTC.

On Mon, Apr 27, 2020 at 2:31 PM Lassi Kortela <address@hidden> wrote:
SRFI 174 (POSIX Timespecs) provides a datatype for a seconds-nanoseconds
pair. <>

It doesn't define any procedures to get the current time.

reply via email to

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