Subject: Re: bug#39668: 26.2; timer-list and timer-idle-list are undocumented in the Elisp manual

From: Eli Zaretskii <[email-masked]>
Date: Tue, 18 Feb 2020 21:26:12 +0200

> Date: Tue, 18 Feb 2020 18:45:56 +0000 (GMT)
> From: ndame <[email-masked]>
> Cc: "[email-masked]" <[email-masked]>
> 
> I needed to access the list of the active timers from an elisp program. 
> Since timers are available from elisp, the list of timers should be 
> available too, like the list of buffers, etc.
> 
> I was suprised that I did not find this in the manual. Since timers are
> part of the public elisp api, I expect timer lists also to be part of the
> public api.

We don't describe those lists intentionally, because messing with them
can produce unexpected results.  Think about that: while you are
modifying the list of timers, some timer might expire, and Emacs will
run it, and modify the list as result.  (We do have protection from at
least the simplest forms of such races, but still, we don't like to
have Lisp programs manipulate those lists.)

Why do you need to access the active timers?