summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
diff options
context:
space:
mode:
authorStefan Kangas <stefan@marxist.se>2020-10-20 19:10:51 +0200
committerStefan Kangas <stefan@marxist.se>2020-10-20 19:14:04 +0200
commit6c58d900427e8195c5cfc37e7422bdb0bc73c047 (patch)
tree18c50f94d1a01f92e51e60f754bedfce7500ae8f /lisp/emacs-lisp
parent4a575eb18cca3eed5019f2d2d2abeea1f0c07005 (diff)
downloademacs-6c58d900427e8195c5cfc37e7422bdb0bc73c047.tar.gz
emacs-6c58d900427e8195c5cfc37e7422bdb0bc73c047.tar.bz2
emacs-6c58d900427e8195c5cfc37e7422bdb0bc73c047.zip
Make more load-hooks obsolete (Bug#21563)
* lisp/progmodes/dcl-mode.el (dcl-mode): * lisp/progmodes/idlw-complete-structtag.el: Recommend with-eval-after-load instead of load-hooks. * lisp/calc/calc-ext.el (calc-ext-load-hook): * lisp/emacs-lisp/bytecomp.el (bytecomp-load-hook): * lisp/emacs-lisp/cl-extra.el (cl-extra-load-hook): * lisp/emacs-lisp/cl-macs.el (cl-macs-load-hook): * lisp/emacs-lisp/cl-seq.el (cl-seq-load-hook): * lisp/gnus/message.el (message-load-hook): * lisp/gnus/nnheader.el (nnheader-load-hook): * lisp/gnus/nnmail.el (nnmail-load-hook): * lisp/progmodes/dcl-mode.el (dcl-mode-load-hook): * lisp/textmodes/tex-mode.el (tex-mode-load-hook): * lisp/whitespace.el (whitespace-load-hook): Obsolete for with-eval-after-load. Note that these variables are never declared, but the byte-compiler will still warn about them if used.
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r--lisp/emacs-lisp/bytecomp.el2
-rw-r--r--lisp/emacs-lisp/cl-extra.el2
-rw-r--r--lisp/emacs-lisp/cl-macs.el2
-rw-r--r--lisp/emacs-lisp/cl-seq.el2
4 files changed, 8 insertions, 0 deletions
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index b63d06a5849..a547b672b1a 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -5259,6 +5259,8 @@ and corresponding effects."
byte-compile-variable-ref))))
nil)
+(make-obsolete-variable 'bytecomp-load-hook
+ "use `with-eval-after-load' instead." "28.1")
(run-hooks 'bytecomp-load-hook)
;;; bytecomp.el ends here
diff --git a/lisp/emacs-lisp/cl-extra.el b/lisp/emacs-lisp/cl-extra.el
index 5bf74792c08..23c784f9f8e 100644
--- a/lisp/emacs-lisp/cl-extra.el
+++ b/lisp/emacs-lisp/cl-extra.el
@@ -910,6 +910,8 @@ Outputs to the current buffer."
(mapc #'cl--describe-class-slot cslots))))
+(make-obsolete-variable 'cl-extra-load-hook
+ "use `with-eval-after-load' instead." "28.1")
(run-hooks 'cl-extra-load-hook)
;; Local variables:
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el
index 147a0a8f5a4..1501ed43082 100644
--- a/lisp/emacs-lisp/cl-macs.el
+++ b/lisp/emacs-lisp/cl-macs.el
@@ -3430,6 +3430,8 @@ STRUCT and SLOT-NAME are symbols. INST is a structure instance."
(nth (cl-struct-slot-offset ,struct-type ,slot-name) ,inst)
(aref ,inst (cl-struct-slot-offset ,struct-type ,slot-name)))))))
+(make-obsolete-variable 'cl-macs-load-hook
+ "use `with-eval-after-load' instead." "28.1")
(run-hooks 'cl-macs-load-hook)
;; Local variables:
diff --git a/lisp/emacs-lisp/cl-seq.el b/lisp/emacs-lisp/cl-seq.el
index f90cce9b471..d34d50172df 100644
--- a/lisp/emacs-lisp/cl-seq.el
+++ b/lisp/emacs-lisp/cl-seq.el
@@ -1042,6 +1042,8 @@ Atoms are compared by `eql'; cons cells are compared recursively.
(and (not (consp cl-x)) (not (consp cl-y)) (cl--check-match cl-x cl-y)))
+(make-obsolete-variable 'cl-seq-load-hook
+ "use `with-eval-after-load' instead." "28.1")
(run-hooks 'cl-seq-load-hook)
;; Local variables: