Re: current-time-list now defaults to nil in Emacs master
Stefan Monnier <[email protected]>
| Newsgroups | gmane.emacs.devel |
|---|---|
| Message-ID | <[email protected]> |
> > The better alternative (beside adjust the code so it works with the new > > format) is to insert a call to `time-convert`, as suggested in the > > `current-time` docstring. > > Some comments for the (my own) record > I spotted a difference (in "legacy code"), [...] > (setq current-time-list nil) > > (setq $a "Fri Aug 14 12:51:33 2026 +0530") > (let ((current-time-list t)) (encode-time (parse-time-string $a))) > ; (27262 49661) > > (time-convert (encode-time (parse-time-string $a)) 'list) > ;(27262 49661 0 0) Interesting. Paul, IIRC this is your code. Is the discrepancy on purpose? > though it probably makes no > difference to code which didnt check for endp cddr Indeed. > Another possible point of tripping is the interpretation of FORM in > time-convert vs the interpretetaion of FORM in decode-time and > parse-time-string That's a long-standing problem, indeed, and I think the (TICKS . HZ) we get with the new default value helps reduce this confusion. === Stefan