bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#55163: 29.0.50; master 4a1f69ebca (TICKS . HZ) for current-time brok


From: Paul Eggert
Subject: bug#55163: 29.0.50; master 4a1f69ebca (TICKS . HZ) for current-time broke lsp-mode
Date: Sat, 30 Apr 2022 14:03:55 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.1

On 4/30/22 02:15, Lars Ingebrigtsen wrote:
* (clock-realtime) returns the system-wide clock. It acts like
   (time-convert nil t), i.e., like (current-time) but returning (TICKS
   . HZ) form.
clock- as a prefix does make a lot of sense, but I think I'd interpret
that as "realtime" as something having to do with scheduling

Yes, "realtime" is an unfortunate phrase here, even if it's POSIX. Perhaps we should use "universal" instead, since it's Universal Time.

Another thought is that instead of a new Lisp function, we could extend current-time. E.g., (current-time 'universal) would return the current time in seconds since the EPOCH, (current-time 'process-cpu) the process's CPU time, (current-time 'monotonic) a monotonic clock, etc. Although this wouldn't let us reorganize the time API in a major way, it would let us add the needed functionality in a way that follows existing practice pretty closely, and there's benefit to that.





reply via email to

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