Subject: bug#56407: 29.0.50; desktop.el shouldn't be saving/restoring eglot--managed-mode, which is not for interactive use

From: João Távora <[email-masked]>
Date: Wed, 6 Jul 2022 14:47:32 +0100

On Wed, Jul 6, 2022 at 2:40 PM Stefan Kangas <[email-masked]> wrote:

> >   (eval-after-load 'desktop
> >    ...)
>
> `with-eval-after-load' is nicer, IMO.
>
> > Then again, eval-after-load shouldn't be used in packages, so I've read
> somewhere
> > (manual?).
>
> See the last paragraph in (info "(elisp) Hooks for Loading")
>

Don't hold me in suspense! :-) what does it say vis-a-vis use in libraries?

Maybe we should just use it. If it works, it's the easiest one and not
terribly
ugly.

Why is it the easiest one?  Because I've just remembered an obvious
drawback of the symbol-property approach: it will only work on Emacs trunk,
_unless_ we make the little dance (that I've done a few times) of making
desktop.el a GNU ELPA :core  package and making eglot.el depend on
that package (which is different from _requiring_ the load of that package).

Lars, what do you think?

João