GNU bug report logs -
#55163
29.0.50; master 4a1f69ebca (TICKS . HZ) for current-time broke lsp-mode
Previous Next
Reported by: Vincenzo Pupillo <v.pupillo <at> gmail.com>
Date: Thu, 28 Apr 2022 10:55:01 UTC
Severity: normal
Found in version 29.0.50
Fixed in version 29.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
On 4/30/22 22:38, Eli Zaretskii wrote:
>> it's common for Emacs to compare the timestamp of a file at
>> time T1 with the timestamp of another (or the same) file at a later
>> time T2.
> Please show at least 3 examples of such "common" situations. I think
> it is rather UN-common.
auth-source-netrc-parse, semanticdb-synchronize, and dir-locals-find-file.
> what's the problem to describe and support a primitive that
> returns a sorted list of files?
What happens with ties in the timestamps - do we sort stably? What
happens with files named but not present? What if we want to sort by
ctime instead of by mtime? What if the user is involved in selecting
files as we go? How do we specify the files: a list of strings, a
pattern, or something else? What if we want to look at a tree of files? Etc.
Of course one could come up with answers to those questions, but this
sort of thing is much better handled in Lisp code than as a C-language
primitive.
> I challenge you to present even half a dozen of such uses.
I listed three examples above. Here are three more, which makes six:
multisession-backend-value, eshell-read-passwd,
nneething-create-mapping. More examples can easily be supplied.
>> There are also cases where the code now uses current-time and assumes
>> that the resulting timestamps are issued in numeric order, an assumption
>> that is not always true in practice.
>
> That's a separate issue, and again: please present the use cases for
> that which are relevant to Emacs applications.
erc-server-send-ping, progress-reporter-do-update, timer-event-handler.
I'm sure there are others.
Your point is well taken that if we made changes along the lines being
discussed, we shouldn't merely add the new primitives: we should *use*
them. And if we can't find significant use for them then we shouldn't
add them.
This bug report was last modified 3 years and 19 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.