On Wed, Dec 21, 2022 at 2:20 PM Eli Zaretskii wrote: > > From: João Távora > > Date: Wed, 21 Dec 2022 14:04:34 +0000 > > Cc: juri@linkov.net, monnier@iro.umontreal.ca, emacs-devel@gnu.org > > > > If we don't preload eldoc, it will be automatically loaded once you do > > "emacs -Q". So it makes no sense not to preload it, > > > > But I can't see how ElDoc can be useful when doing lots of > > things from emacs -Q like adding '--batch -f batch-byte-compile' > > or '--batch -f elisp-flymake--batch-compile-for-flymake', to name > > just two. > > > > Even when just emacs -Q is used, which starts up > > lisp-interaction-mode, which derives from emacs-lisp-mode, it's > > not unthinkable that ElDoc won't be actually needed at all. > > > > So IMO ElDoc should be auto-loaded, but not preloaded. > > There's also another reason to do so: upgrading ElDoc via > > M-x package-install (note that it is a :core GNU ELPA package) > > is, last time I checked, made more difficult, and requires the > > user to restart Emacs. > > If you want to lobby for disabling ElDoc by default, feel free (and > good luck!). But that is a different discussion. > Yes, that is a prerequisite, of course. AFAICT there is no reason to global-eldoc-mode enabled globally (or really, to have that variable at all). Major modes and minor modes (like elisp-mode or eglot), which are its clients, and which want to keep the can use add-hook and have it load just-in-time when (eldoc-mode 1) happens or somesuch. > Our policy and practice was since long ago that any package which is > always or almost always loaded at startup without any user say-so, > should be preloaded, since not doing that makes very little sense. So > until and unless we decide to disable ElDoc, it should stay preloaded. > Makes sense, of course. And I think Juri's point is that cl-lib.el is among those relatively small packages which is "almost always loaded". João