Pacify recent unused/ignored lexvar warnings

Lexvars with special names like 'ignored' or 'unused' are no longer
treated specially.

* lisp/ansi-color.el (ansi-color-process-output):
* lisp/cus-edit.el (customize-apropos-options):
* lisp/cus-theme.el (customize-create-theme):
* lisp/dired-aux.el (dired-hide-all):
* lisp/emacs-lisp/crm.el (crm--choose-completion-string):
* lisp/emacs-lisp/tabulated-list.el (tabulated-list-revert):
* lisp/ido.el (ido-choose-completion-string):
* lisp/international/mule-diag.el (describe-font-internal):
* lisp/mail/sendmail.el (sendmail-user-agent-compose):
* lisp/progmodes/fortran.el (fortran-uncomment-region):
* lisp/progmodes/prolog.el (prolog-inferior-guess-flavor):
* lisp/progmodes/ruby-mode.el (ruby-indent-line, ruby-indent-exp):
* lisp/url/url.el (url-mm-callback):
* lisp/xwidget.el (xwidget-webkit-history-reload): Prepend an
underscore to unused function parameter names.
* lisp/emacs-lisp/cconv.el (cconv--dummy-var): Remove unused
constant.
* lisp/files.el (hack-local-variables-filter): Remove unused lexvar.
This commit is contained in:
Basil L. Contovounesios 2022-10-26 16:35:59 +03:00
parent 32dd769ca4
commit 38bcad5451
16 changed files with 19 additions and 21 deletions

View file

@ -418,7 +418,7 @@ and it should apply face FACE to the text between BEG and END.")
(setq ansi-color-for-comint-mode 'filter))
;;;###autoload
(defun ansi-color-process-output (ignored)
(defun ansi-color-process-output (_ignored)
"Maybe translate SGR control sequences of comint output into text properties.
Depending on variable `ansi-color-for-comint-mode' the comint output is

View file

@ -1546,7 +1546,7 @@ If TYPE is `groups', include only groups."
"*Customize Apropos*")))
;;;###autoload
(defun customize-apropos-options (regexp &optional ignored)
(defun customize-apropos-options (regexp &optional _ignored)
"Customize all loaded customizable options matching REGEXP."
(interactive (list (apropos-read-pattern "options")))
(customize-apropos regexp 'options))

View file

@ -142,7 +142,7 @@ remove them from your saved Custom file.\n\n")
(widget-create 'push-button
:tag " Revert "
:help-echo "Revert this buffer to its original state."
:action (lambda (&rest ignored) (revert-buffer)))
:action (lambda (&rest _ignored) (revert-buffer)))
(widget-insert "\n\nTheme name : ")
(setq custom-theme-name

View file

@ -3478,7 +3478,7 @@ Use \\[dired-hide-all] to (un)hide all directories."
(dired-next-subdir 1 t))))
;;;###autoload
(defun dired-hide-all (&optional ignored)
(defun dired-hide-all (&optional _ignored)
"Hide all subdirectories, leaving only their header lines.
If there is already something hidden, make everything visible again.
Use \\[dired-hide-subdir] to (un)hide a particular subdirectory."

View file

@ -130,8 +130,6 @@ Returns a form where all lambdas don't have any free variables."
(prog1 (cconv-convert form nil nil) ; Env initially empty.
(cl-assert (null cconv-freevars-alist)))))
(defconst cconv--dummy-var (make-symbol "ignored"))
(defun cconv--set-diff (s1 s2)
"Return elements of set S1 that are not in set S2."
(let ((res '()))

View file

@ -201,7 +201,7 @@ This function is modeled after `minibuffer-complete-and-exit'."
(if doexit (exit-minibuffer))))
(defun crm--choose-completion-string (choice buffer base-position
&rest ignored)
&rest _ignored)
"Completion string chooser for `completing-read-multiple'.
This is called from `choose-completion-string-functions'.
It replaces the string that is currently being completed, without

View file

@ -374,7 +374,7 @@ Optional arg POS is a buffer position where to look for a fake header;
defaults to `point-min'."
(overlays-at (or pos (point-min))))
(defun tabulated-list-revert (&rest ignored)
(defun tabulated-list-revert (&rest _ignored)
"The `revert-buffer-function' for `tabulated-list-mode'.
It runs `tabulated-list-revert-hook', then calls `tabulated-list-print'."
(interactive)

View file

@ -3863,7 +3863,7 @@ If these settings come from directory-local variables, then
DIR-NAME is the name of the associated directory. Otherwise it is nil."
;; Find those variables that we may want to save to
;; `safe-local-variable-values'.
(let (all-vars risky-vars unsafe-vars ignored)
(let (all-vars risky-vars unsafe-vars)
(dolist (elt variables)
(let ((var (car elt))
(val (cdr elt)))

View file

@ -3915,7 +3915,7 @@ If `ido-change-word-sub' cannot be found in WORD, return nil."
"Return dotted pair (RES . 1)."
(cons res 1))
(defun ido-choose-completion-string (choice &rest ignored)
(defun ido-choose-completion-string (choice &rest _ignored)
(when (ido-active)
;; Insert the completion into the buffer where completion was requested.
(and ido-completion-buffer

View file

@ -812,7 +812,7 @@ but still contains full information about each coding system."
(declare-function font-info "font.c" (name &optional frame))
(defun describe-font-internal (font-info &optional ignored)
(defun describe-font-internal (font-info &optional _ignored)
"Print information about a font in FONT-INFO.
The IGNORED argument is ignored."
(print-list "name (opened by):" (aref font-info 0))

View file

@ -550,10 +550,10 @@ This also saves the value of `send-mail-function' via Customize."
#'mail-send-and-exit)
;;;###autoload
(defun sendmail-user-agent-compose (&optional to subject other-headers
continue switch-function yank-action
send-actions return-action
&rest ignored)
(defun sendmail-user-agent-compose ( &optional to subject other-headers
continue switch-function yank-action
send-actions return-action
&rest _ignored )
(if switch-function
(funcall switch-function "*mail*"))
(let ((cc (cdr (assoc-string "cc" other-headers t)))

View file

@ -957,7 +957,7 @@ With non-nil ARG, uncomments the region."
(set-marker save-point nil)))
;; uncomment-region calls this with 3 args.
(defun fortran-uncomment-region (start end &optional ignored)
(defun fortran-uncomment-region (start end &optional _ignored)
"Uncomment every line in the region."
(fortran-comment-region start end t))

View file

@ -1311,7 +1311,7 @@ With prefix argument ARG, restart the Prolog process if running before."
(prolog-mode-variables)
))
(defun prolog-inferior-guess-flavor (&optional ignored)
(defun prolog-inferior-guess-flavor (&optional _ignored)
(setq-local prolog-system
(when (or (numberp prolog-system) (markerp prolog-system))
(save-excursion

View file

@ -849,7 +849,7 @@ The style of the comment is controlled by `ruby-encoding-magic-comment-style'."
(back-to-indentation)
(current-column)))
(defun ruby-indent-line (&optional ignored)
(defun ruby-indent-line (&optional _ignored)
"Correct the indentation of the current Ruby line."
(interactive)
(ruby-indent-to (ruby-calculate-indent)))
@ -1576,7 +1576,7 @@ With ARG, do it many times. Negative ARG means move forward."
((error)))
i))))
(defun ruby-indent-exp (&optional ignored)
(defun ruby-indent-exp (&optional _ignored)
"Indent each line in the balanced expression following the point."
(interactive "*P")
(let ((here (point-marker)) start top column (nest t))

View file

@ -293,7 +293,7 @@ how long to wait for a response before giving up."
(declare-function mm-display-part "mm-decode"
(handle &optional no-default force))
(defun url-mm-callback (&rest ignored)
(defun url-mm-callback (&rest _ignored)
(let ((handle (mm-dissect-buffer t)))
(url-mark-buffer-as-dead (current-buffer))
(with-current-buffer

View file

@ -1198,7 +1198,7 @@ Press \\<xwidget-webkit-isearch-mode-map>\\[xwidget-webkit-isearch-exit] to exit
(xwidget-webkit-goto-history xwidget-webkit-history--session id))
(xwidget-webkit-history-reload))
(defun xwidget-webkit-history-reload (&rest ignored)
(defun xwidget-webkit-history-reload (&rest _ignored)
"Reload the current history buffer."
(interactive)
(setq tabulated-list-entries nil)