1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-25 10:47:00 +00:00

Address some "unused lexical variable" warnings

* lisp/dframe.el (x-sensitive-text-pointer-shape, x-pointer-shape): Declare.

* lisp/eshell/esh-io.el (x-select-enable-clipboard): Declare.

* lisp/erc/erc-button.el (erc-button-add-buttons):
* lisp/eshell/em-cmpl.el (eshell-complete-parse-arguments):
* lisp/eshell/em-hist.el (eshell/history, eshell-isearch-backward):
* lisp/eshell/em-pred.el (eshell-parse-modifiers, eshell-pred-file-time):
Remove unused local variables.
This commit is contained in:
Glenn Morris 2013-09-17 21:48:00 -04:00
parent 35cc47373e
commit 49a053fc5b
8 changed files with 25 additions and 8 deletions

View File

@ -1,5 +1,14 @@
2013-09-18 Glenn Morris <rgm@gnu.org> 2013-09-18 Glenn Morris <rgm@gnu.org>
* dframe.el (x-sensitive-text-pointer-shape, x-pointer-shape): Declare.
* eshell/em-cmpl.el (eshell-complete-parse-arguments):
* eshell/em-hist.el (eshell/history, eshell-isearch-backward):
* eshell/em-pred.el (eshell-parse-modifiers, eshell-pred-file-time):
Remove unused local variables.
* eshell/esh-io.el (x-select-enable-clipboard): Declare.
* textmodes/two-column.el: Make 2C-split work for --without-x. * textmodes/two-column.el: Make 2C-split work for --without-x.
(scroll-bar-columns): Autoload. (scroll-bar-columns): Autoload.
(top-level): Require fringe when compiling. (top-level): Require fringe when compiling.

View File

@ -243,6 +243,9 @@ Local to those buffers, as a function called that created it.")
"Return non-nil if FRAME is currently available." "Return non-nil if FRAME is currently available."
(and frame (frame-live-p frame) (frame-visible-p frame))) (and frame (frame-live-p frame) (frame-visible-p frame)))
(defvar x-sensitive-text-pointer-shape)
(defvar x-pointer-shape)
(defun dframe-frame-mode (arg frame-var cache-var buffer-var frame-name (defun dframe-frame-mode (arg frame-var cache-var buffer-var frame-name
local-mode-fn local-mode-fn
&optional &optional

View File

@ -1,3 +1,7 @@
2013-09-18 Glenn Morris <rgm@gnu.org>
* erc-button.el (erc-button-add-buttons): Remove unused local vars.
2013-09-14 Vivek Dasmohapatra <vivek@etla.org> 2013-09-14 Vivek Dasmohapatra <vivek@etla.org>
* erc.el (erc-update-mode-line-buffer): * erc.el (erc-update-mode-line-buffer):

View File

@ -267,7 +267,7 @@ specified by `erc-button-alist'."
(inhibit-point-motion-hooks t) (inhibit-point-motion-hooks t)
(inhibit-field-text-motion t) (inhibit-field-text-motion t)
(alist erc-button-alist) (alist erc-button-alist)
entry regexp data) regexp)
(erc-button-remove-old-buttons) (erc-button-remove-old-buttons)
(dolist (entry alist) (dolist (entry alist)
(if (equal (car entry) (quote (quote nicknames))) (if (equal (car entry) (quote (quote nicknames)))

View File

@ -370,7 +370,7 @@ to writing a completion function."
(cl-assert (= (length args) (length posns))) (cl-assert (= (length args) (length posns)))
(let ((a args) (let ((a args)
(i 0) (i 0)
l final) l)
(while a (while a
(if (and (consp (car a)) (if (and (consp (car a))
(eq (caar a) 'eshell-operator)) (eq (caar a) 'eshell-operator))

View File

@ -330,7 +330,7 @@ unless a different file is specified on the command line.")
(and (or (not (ring-p eshell-history-ring)) (and (or (not (ring-p eshell-history-ring))
(ring-empty-p eshell-history-ring)) (ring-empty-p eshell-history-ring))
(error "No history")) (error "No history"))
(let (length command file) (let (length file)
(when (and args (string-match "^[0-9]+$" (car args))) (when (and args (string-match "^[0-9]+$" (car args)))
(setq length (min (eshell-convert (car args)) (setq length (min (eshell-convert (car args))
(ring-length eshell-history-ring)) (ring-length eshell-history-ring))
@ -346,8 +346,7 @@ unless a different file is specified on the command line.")
(write-history (eshell-write-history file)) (write-history (eshell-write-history file))
(append-history (eshell-write-history file t)) (append-history (eshell-write-history file t))
(t (t
(let* ((history nil) (let* ((index (1- (or length (ring-length eshell-history-ring))))
(index (1- (or length (ring-length eshell-history-ring))))
(ref (- (ring-length eshell-history-ring) index))) (ref (- (ring-length eshell-history-ring) index)))
;; We have to build up a list ourselves from the ring vector. ;; We have to build up a list ourselves from the ring vector.
(while (>= index 0) (while (>= index 0)
@ -945,7 +944,7 @@ If N is negative, search backwards for the -Nth previous match."
(defun eshell-isearch-backward (&optional invert) (defun eshell-isearch-backward (&optional invert)
"Do incremental regexp search backward through past commands." "Do incremental regexp search backward through past commands."
(interactive) (interactive)
(let ((inhibit-read-only t) end) (let ((inhibit-read-only t))
(eshell-prepare-for-search) (eshell-prepare-for-search)
(goto-char (point-max)) (goto-char (point-max))
(set-marker eshell-last-output-end (point)) (set-marker eshell-last-output-end (point))

View File

@ -306,7 +306,7 @@ predicate functions. MOD-FUNC-LIST is a list of result modifier
functions. PRED-FUNCS take a filename and return t if the test functions. PRED-FUNCS take a filename and return t if the test
succeeds; MOD-FUNCS take any string and preform a modification, succeeds; MOD-FUNCS take any string and preform a modification,
returning the resultant string." returning the resultant string."
(let (result negate follow preds mods) (let (negate follow preds mods)
(condition-case nil (condition-case nil
(while (not (eobp)) (while (not (eobp))
(let ((char (char-after))) (let ((char (char-after)))
@ -399,7 +399,7 @@ returning the resultant string."
(defun eshell-pred-file-time (mod-char mod-type attr-index) (defun eshell-pred-file-time (mod-char mod-type attr-index)
"Return a predicate to test whether a file matches a certain time." "Return a predicate to test whether a file matches a certain time."
(let* ((quantum 86400) (let* ((quantum 86400)
qual amount when open close end) qual when open close end)
(when (memq (char-after) '(?M ?w ?h ?m ?s)) (when (memq (char-after) '(?M ?w ?h ?m ?s))
(setq quantum (char-after)) (setq quantum (char-after))
(cond (cond

View File

@ -118,6 +118,8 @@ from executing while Emacs is redisplaying."
:type 'integer :type 'integer
:group 'eshell-io) :group 'eshell-io)
(defvar x-select-enable-clipboard) ; term/common-win
(defcustom eshell-virtual-targets (defcustom eshell-virtual-targets
'(("/dev/eshell" eshell-interactive-print nil) '(("/dev/eshell" eshell-interactive-print nil)
("/dev/kill" (lambda (mode) ("/dev/kill" (lambda (mode)