summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2022-06-17 18:19:02 +0200
committerLars Ingebrigtsen <larsi@gnus.org>2022-06-17 18:19:02 +0200
commit0edc2f4901f606a9a298edbc2ddc630a44f04a26 (patch)
treecbbc4005fed51fb1fcaff0d52355d1d1c22fb8b9
parentda8fed0be06dc1ba936bfaa427f0890c881f133a (diff)
downloademacs-0edc2f4901f606a9a298edbc2ddc630a44f04a26.tar.gz
Fix some declare-after-interactive functions
* lisp/progmodes/opascal.el (opascal-new-comment-line): * lisp/image-mode.el (image-transform-fit-to-height): * lisp/help-fns.el (help-fns-edit-variable): * lisp/gnus/gnus-salt.el (gnus-pick-start-reading): * lisp/eshell/esh-util.el (eshell-for): * lisp/ldefs-boot.el (view-return-to-alist-update): Fix warnings about declare after interactive.
-rw-r--r--lisp/eshell/esh-util.el3
-rw-r--r--lisp/gnus/gnus-salt.el4
-rw-r--r--lisp/help-fns.el2
-rw-r--r--lisp/image-mode.el2
-rw-r--r--lisp/progmodes/opascal.el2
5 files changed, 5 insertions, 8 deletions
diff --git a/lisp/eshell/esh-util.el b/lisp/eshell/esh-util.el
index b5a423f0237..6b864983995 100644
--- a/lisp/eshell/esh-util.el
+++ b/lisp/eshell/esh-util.el
@@ -303,8 +303,7 @@ Prepend remote identification of `default-directory', if any."
(defmacro eshell-for (for-var for-list &rest forms)
"Iterate through a list."
- (declare (obsolete dolist "24.1"))
- (declare (indent 2))
+ (declare (obsolete dolist "24.1") (indent 2))
`(let ((list-iter ,for-list))
(while list-iter
(let ((,for-var (car list-iter)))
diff --git a/lisp/gnus/gnus-salt.el b/lisp/gnus/gnus-salt.el
index 3189655c8ad..4ef2ebf1dd7 100644
--- a/lisp/gnus/gnus-salt.el
+++ b/lisp/gnus/gnus-salt.el
@@ -133,9 +133,7 @@ It accepts the same format specs that `gnus-summary-line-format' does."
(defun gnus-pick-start-reading (&optional catch-up)
"Start reading the picked articles.
If given a prefix, mark all unpicked articles as read."
- (interactive "P")
- (declare (completion (lambda (s b)
- (completion-minor-mode-active-p s b 'gnus-pick-mode))))
+ (interactive "P" gnus-pick-mode)
(if gnus-newsgroup-processable
(progn
(gnus-summary-limit-to-articles nil)
diff --git a/lisp/help-fns.el b/lisp/help-fns.el
index 18b12ee7b37..6eff0b9b0e9 100644
--- a/lisp/help-fns.el
+++ b/lisp/help-fns.el
@@ -1372,8 +1372,8 @@ it is displayed along with the global value."
(put 'help-fns-edit-variable 'disabled t)
(defun help-fns-edit-variable ()
"Edit the variable under point."
- (interactive)
(declare (completion ignore))
+ (interactive)
(let ((var (get-text-property (point) 'help-fns--edit-variable)))
(unless var
(error "No variable under point"))
diff --git a/lisp/image-mode.el b/lisp/image-mode.el
index ea5d7ff0f35..684f2ff3fc1 100644
--- a/lisp/image-mode.el
+++ b/lisp/image-mode.el
@@ -1559,8 +1559,8 @@ return value is suitable for appending to an image spec."
(defun image-transform-fit-to-height ()
"Fit the current image to the height of the current window."
- (interactive)
(declare (obsolete nil "29.1"))
+ (interactive)
(setq image-transform-resize 'fit-height)
(image-toggle-display-image))
diff --git a/lisp/progmodes/opascal.el b/lisp/progmodes/opascal.el
index 4ab9b4a9962..63399adf3ae 100644
--- a/lisp/progmodes/opascal.el
+++ b/lisp/progmodes/opascal.el
@@ -1641,10 +1641,10 @@ An error is raised if not in a comment."
(defun opascal-new-comment-line ()
"If in a // comment, do a newline, indented such that one is still in the
comment block. If not in a // comment, just does a normal newline."
- (interactive)
(declare
(obsolete "use comment-indent-new-line with comment-multi-line instead"
"27.1"))
+ (interactive)
(let ((comment (opascal-current-token)))
(if (not (eq 'comment-single-line (opascal-token-kind comment)))
;; Not in a // comment. Just do the normal newline.