[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#21563: 24.5; discourage load-hook variables
From: |
Drew Adams |
Subject: |
bug#21563: 24.5; discourage load-hook variables |
Date: |
Thu, 16 Jan 2020 08:15:58 -0800 (PST) |
> To summarize what has come up in this thread so far, the load-hook
> convention has the following problems:
>
> 1. They are never called if set by a user after a library is loaded.
> 2. They can lead to issues like Bug#24491.
> 3. They require every package (that wants to use them) to add boiler
> plate code.
>
> They are also redundant since we have eval-after-load and
> with-eval-after-load, which do not have any of the above problems.
Here's what I'd suggest, if you are bent on removing
all load hooks and deprecating them:
1. Try removing all of them from the vanilla
(distributed) Elisp code.
2. Run with that for a major release or two. If no
problems, then deprecate (declare obsolete).
Doing the second first (at the outset) makes no sense
to me. Try it first. Those hooks were added, over
time, at specific spots in the Emacs code for a reason,
presumably - at least some of them were deliberate, we
can suppose.
(Load hooks were never added to "every package". And
I doubt that, at least in some cases, they were just
added as "boiler plate code". Please try to find out
why given a package "wants to use them" before removing.)
I don't see why it would make sense to just suppose
that this is all unnecessary cruft, and tell users
to start removing their own such, without any trial
of removing it from the Emacs code first.
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Drew Adams, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Glenn Morris, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Drew Adams, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Drew Adams, 2020/01/15
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/16
- bug#21563: 24.5; discourage load-hook variables,
Drew Adams <=
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/16
- bug#21563: 24.5; discourage load-hook variables, Drew Adams, 2020/01/16
- bug#21563: 24.5; discourage load-hook variables, Noam Postavsky, 2020/01/16
- bug#21563: 24.5; discourage load-hook variables, Drew Adams, 2020/01/16
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/16
- bug#21563: 24.5; discourage load-hook variables, Stefan Kangas, 2020/01/15