1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-07 15:00:34 -08:00

lisp/*: Add declarations, remove unused bindings, mark unused args.

* lisp/avoid.el (mouse-avoidance-mode): Mark unused arg.
  (mouse-avoidance-nudge-mouse): Remove unused binding.

* lisp/imenu.el (imenu-default-goto-function): Mark unused args.
  (imenu-progress-message): Remove obsolete macro; all callers changed.

* lisp/mouse.el (mouse-menu-major-mode-map):
* lisp/emacs-lisp/authors.el (authors-scan-change-log)
  (authors-add-to-author-list):
* lisp/emacs-lisp/avl-tree.el (avl-tree--enter-balance):
* lisp/emacs-lisp/smie.el (smie-auto-fill):
* lisp/mail/sendmail.el (mail-bury):
* lisp/mail/unrmail.el (unrmail):
* lisp/net/tls.el (open-tls-stream):
* lisp/textmodes/picture.el (picture-mouse-set-point):
  Remove unused bindings.

* lisp/subr.el (keymap-canonicalize): Remove unused binding.
  (read-passwd): Mark unused arg.

* lisp/tutorial.el (tutorial--display-changes): Remove unused binding.
  (tutorial--save-tutorial-to): Remove unused variable.

* lisp/emacs-lisp/package.el (define-package, package-menu-mark-delete)
  (package-menu-mark-install, package-menu-mark-unmark): Mark unused args.
  (package-generate-autoloads, package-menu--generate)
  (package-menu--find-upgrades): Remove unused bindings.

* lisp/emulation/cua-rect.el (cua-restrict-regexp-rectangle)
  (cua-restrict-prefix-rectangle): Doc fixes.  Remove unused bindings.
  (cua--mouse-ignore, cua--delete-rectangle, cua--extract-rectangle)
  (cua--indent-rectangle, cua-open-rectangle, cua-close-rectangle)
  (cua-blank-rectangle, cua-string-rectangle, cua-replace-in-rectangle)
  (cua-incr-rectangle, cua-sequence-rectangle, cua--convert-rectangle-as)
  (cua--rectangle-aux-replace, cua--left-fill-rectangle)
  (cua-scroll-rectangle-up, cua-scroll-rectangle-down)
  (cua-delete-char-rectangle): Mark unused args.
  (cua-align-rectangle): Remove unused binding.

* lisp/mail/rmail.el (compilation--message->loc)
  (epa--find-coding-system-for-mime-charset): Declare.

* lisp/net/dbus.el (dbus-register-service): Declare.
  (dbus-name-owner-changed-handler): Remove unused binding.

* lisp/nxml/nxml-mode.el (nxml-electric-slash, nxml-in-mixed-content-p)
  (nxml-compute-indent-from-matching-start-tag): Remove unused variables.
  (nxml-scan-backward-within): Mark unused arg.
  (nxml-dynamic-markup-word): Remove unused binding.
This commit is contained in:
Juanma Barranquero 2012-04-19 19:20:26 +02:00
parent 376cbaccd9
commit 4d6769e1bb
18 changed files with 138 additions and 129 deletions

View file

@ -1,4 +1,4 @@
;;; authors.el --- utility for maintaining Emacs's AUTHORS file -*-coding: utf-8;-*-
;;; authors.el --- utility for maintaining Emacs's AUTHORS file -*-coding: utf-8 -*-
;; Copyright (C) 2000-2012 Free Software Foundation, Inc.
@ -829,7 +829,7 @@ with the file and the number of each action:
(enable-local-eval nil)
(existing-buffer (get-file-buffer log-file))
(buffer (find-file-noselect log-file))
authors file pos)
authors pos)
(with-current-buffer buffer
(save-restriction
(widen)
@ -943,8 +943,7 @@ and changed by AUTHOR."
(file (car change))
(filestat (if (authors-public-domain-p file)
(concat file " (public domain)")
file))
slot)
file)))
(cond ((assq :wrote actions)
(setq wrote-list (cons filestat wrote-list)))
((assq :cowrote actions)

View file

@ -260,7 +260,7 @@ Return t if the height of the tree has grown."
(opp (avl-tree--switch-dir dir))
;; direction 0,1 -> sign factor -1,+1
(sgn (avl-tree--dir-to-sign dir))
p1 p2 b2 result)
p1 p2 b2)
(cond
((< (* sgn (avl-tree--node-balance br)) 0)
(setf (avl-tree--node-balance br) 0)

View file

@ -524,7 +524,7 @@ Required package `%s-%s' is unavailable"
(defun define-package (name-string version-string
&optional docstring requirements
&rest extra-properties)
&rest _extra-properties)
"Define a new package.
NAME-STRING is the name of the package, as a string.
VERSION-STRING is the version of the package, as a string.
@ -584,7 +584,7 @@ EXTRA-PROPERTIES is currently unused."
(defun package-generate-autoloads (name pkg-dir)
(require 'autoload) ;Load before we let-bind generated-autoload-file!
(let* ((auto-name (concat name "-autoloads.el"))
(ignore-name (concat name "-pkg.el"))
;;(ignore-name (concat name "-pkg.el"))
(generated-autoload-file (expand-file-name auto-name pkg-dir))
(version-control 'never))
(unless (fboundp 'autoload-ensure-default-file)
@ -1389,7 +1389,7 @@ If REMEMBER-POS is non-nil, keep point on the same entry.
PACKAGES should be t, which means to display all known packages,
or a list of package names (symbols) to display."
;; Construct list of ((PACKAGE . VERSION) STATUS DESCRIPTION).
(let (info-list name builtin)
(let (info-list name)
;; Installed packages:
(dolist (elt package-alist)
(setq name (car elt))
@ -1474,21 +1474,21 @@ If optional arg BUTTON is non-nil, describe its associated package."
(describe-package package))))
;; fixme numeric argument
(defun package-menu-mark-delete (&optional num)
(defun package-menu-mark-delete (&optional _num)
"Mark a package for deletion and move to the next line."
(interactive "p")
(if (member (package-menu-get-status) '("installed" "obsolete"))
(tabulated-list-put-tag "D" t)
(forward-line)))
(defun package-menu-mark-install (&optional num)
(defun package-menu-mark-install (&optional _num)
"Mark a package for installation and move to the next line."
(interactive "p")
(if (string-equal (package-menu-get-status) "available")
(tabulated-list-put-tag "I" t)
(forward-line)))
(defun package-menu-mark-unmark (&optional num)
(defun package-menu-mark-unmark (&optional _num)
"Clear any marks on a package and move to the next line."
(interactive "p")
(tabulated-list-put-tag " " t))
@ -1530,8 +1530,7 @@ If optional arg BUTTON is non-nil, describe its associated package."
(dolist (entry tabulated-list-entries)
;; ENTRY is ((NAME . VERSION) [NAME VERSION STATUS DOC])
(let ((pkg (car entry))
(status (aref (cadr entry) 2))
old)
(status (aref (cadr entry) 2)))
(cond ((equal status "installed")
(push pkg installed))
((equal status "available")

View file

@ -1603,8 +1603,7 @@ to which that point should be aligned, if we were to reindent it.")
(indent-line-to indent)))))
(defun smie-auto-fill ()
(let ((fc (current-fill-column))
(try-again nil))
(let ((fc (current-fill-column)))
(while (and fc (> (current-column) fc))
(cond
((not (or (nth 8 (save-excursion
@ -1628,7 +1627,6 @@ to which that point should be aligned, if we were to reindent it.")
(setq bsf (point))))
(smie-indent-forward-token))
(when (> gain 0)
(setq try-again)
(goto-char bsf)
(newline-and-indent)))))
(t (do-auto-fill))))))