diff options
| author | Stefan Monnier | 2017-03-18 22:32:23 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2017-03-18 22:32:23 -0400 |
| commit | 06a796398646fd1a5e17bc7321e12ae8e061e7f7 (patch) | |
| tree | c6d37953b3d11e3f5e7e3f390a421355a4d2769c | |
| parent | 32bb5a945a47b14fa85dc1c2f1776b6baa3b0dcc (diff) | |
| download | emacs-06a796398646fd1a5e17bc7321e12ae8e061e7f7.tar.gz emacs-06a796398646fd1a5e17bc7321e12ae8e061e7f7.zip | |
Remove unused vars in cl-extra.el and tramp.el.
* lisp/emacs-lisp/cl-extra.el (cl--print-table): Remove unused vars.
* lisp/net/tramp.el (tramp-dissect-file-name): Remove unused `match'.
(outline-regexp, ls-lisp-use-insert-directory-program): Declare.
(tramp-find-foreign-file-name-handler): Mark unused arg, remove unused `v`.
| -rw-r--r-- | lisp/emacs-lisp/cl-extra.el | 14 | ||||
| -rw-r--r-- | lisp/net/tramp.el | 12 |
2 files changed, 14 insertions, 12 deletions
diff --git a/lisp/emacs-lisp/cl-extra.el b/lisp/emacs-lisp/cl-extra.el index 8b3d6eecf5c..021ef232749 100644 --- a/lisp/emacs-lisp/cl-extra.el +++ b/lisp/emacs-lisp/cl-extra.el | |||
| @@ -877,16 +877,14 @@ including `cl-block' and `cl-eval-when'." | |||
| 877 | (if (> newwidth curwidth) | 877 | (if (> newwidth curwidth) |
| 878 | (setf (aref cols i) newwidth))))) | 878 | (setf (aref cols i) newwidth))))) |
| 879 | (let ((formats '()) | 879 | (let ((formats '()) |
| 880 | (tmp-head header) | ||
| 881 | (col 0)) | 880 | (col 0)) |
| 882 | (dotimes (i (length cols)) | 881 | (dotimes (i (length cols)) |
| 883 | (let ((head (pop tmp-head))) | 882 | (push (concat (propertize " " |
| 884 | (push (concat (propertize " " | 883 | 'display |
| 885 | 'display | 884 | `(space :align-to ,(+ col col-space))) |
| 886 | `(space :align-to ,(+ col col-space))) | 885 | "%s") |
| 887 | "%s") | 886 | formats) |
| 888 | formats) | 887 | (cl-incf col (+ col-space (aref cols i)))) |
| 889 | (cl-incf col (+ col-space (aref cols i))))) | ||
| 890 | (let ((format (mapconcat #'identity (nreverse formats) ""))) | 888 | (let ((format (mapconcat #'identity (nreverse formats) ""))) |
| 891 | (insert (apply #'format format | 889 | (insert (apply #'format format |
| 892 | (mapcar (lambda (str) (propertize str 'face 'italic)) | 890 | (mapcar (lambda (str) (propertize str 'face 'italic)) |
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 969092f517f..fdd4661decb 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -1237,7 +1237,8 @@ values." | |||
| 1237 | (save-match-data | 1237 | (save-match-data |
| 1238 | (unless (tramp-tramp-file-p name) | 1238 | (unless (tramp-tramp-file-p name) |
| 1239 | (tramp-compat-user-error nil "Not a Tramp file name: \"%s\"" name)) | 1239 | (tramp-compat-user-error nil "Not a Tramp file name: \"%s\"" name)) |
| 1240 | (let ((match (string-match (nth 0 tramp-file-name-structure) name))) | 1240 | (if (not (string-match (nth 0 tramp-file-name-structure) name)) |
| 1241 | (error "`tramp-file-name-structure' didn't match!") | ||
| 1241 | (let ((method (match-string (nth 1 tramp-file-name-structure) name)) | 1242 | (let ((method (match-string (nth 1 tramp-file-name-structure) name)) |
| 1242 | (user (match-string (nth 2 tramp-file-name-structure) name)) | 1243 | (user (match-string (nth 2 tramp-file-name-structure) name)) |
| 1243 | (host (match-string (nth 3 tramp-file-name-structure) name)) | 1244 | (host (match-string (nth 3 tramp-file-name-structure) name)) |
| @@ -1373,6 +1374,8 @@ Point must be at the beginning of a header line. | |||
| 1373 | The outline level is equal to the verbosity of the Tramp message." | 1374 | The outline level is equal to the verbosity of the Tramp message." |
| 1374 | (1+ (string-to-number (match-string 1)))) | 1375 | (1+ (string-to-number (match-string 1)))) |
| 1375 | 1376 | ||
| 1377 | (defvar outline-regexp) | ||
| 1378 | |||
| 1376 | (defun tramp-get-debug-buffer (vec) | 1379 | (defun tramp-get-debug-buffer (vec) |
| 1377 | "Get the debug buffer for VEC." | 1380 | "Get the debug buffer for VEC." |
| 1378 | (with-current-buffer | 1381 | (with-current-buffer |
| @@ -1969,11 +1972,10 @@ ARGS are the arguments OPERATION has been called with." | |||
| 1969 | ;; Unknown file primitive. | 1972 | ;; Unknown file primitive. |
| 1970 | (t (error "unknown file I/O primitive: %s" operation)))) | 1973 | (t (error "unknown file I/O primitive: %s" operation)))) |
| 1971 | 1974 | ||
| 1972 | (defun tramp-find-foreign-file-name-handler (filename &optional operation) | 1975 | (defun tramp-find-foreign-file-name-handler (filename &optional _operation) |
| 1973 | "Return foreign file name handler if exists." | 1976 | "Return foreign file name handler if exists." |
| 1974 | (when (tramp-tramp-file-p filename) | 1977 | (when (tramp-tramp-file-p filename) |
| 1975 | (let ((v (tramp-dissect-file-name filename t)) | 1978 | (let ((handler tramp-foreign-file-name-handler-alist) |
| 1976 | (handler tramp-foreign-file-name-handler-alist) | ||
| 1977 | elt res) | 1979 | elt res) |
| 1978 | (while handler | 1980 | (while handler |
| 1979 | (setq elt (car handler) | 1981 | (setq elt (car handler) |
| @@ -2953,6 +2955,8 @@ User is always nil." | |||
| 2953 | backup-directory-alist))) | 2955 | backup-directory-alist))) |
| 2954 | (tramp-run-real-handler 'find-backup-file-name (list filename))))) | 2956 | (tramp-run-real-handler 'find-backup-file-name (list filename))))) |
| 2955 | 2957 | ||
| 2958 | (defvar ls-lisp-use-insert-directory-program) | ||
| 2959 | |||
| 2956 | (defun tramp-handle-insert-directory | 2960 | (defun tramp-handle-insert-directory |
| 2957 | (filename switches &optional wildcard full-directory-p) | 2961 | (filename switches &optional wildcard full-directory-p) |
| 2958 | "Like `insert-directory' for Tramp files." | 2962 | "Like `insert-directory' for Tramp files." |