diff options
| author | Ivan Shmakov | 2015-01-17 18:57:04 +0000 |
|---|---|---|
| committer | Ivan Shmakov | 2015-01-17 19:33:08 +0000 |
| commit | 3e824b05af3a75768a61001fad68e2340af810eb (patch) | |
| tree | db1452b8b50e5c9b000a47098358ca4f6a0bfee5 | |
| parent | 22441b69cb6b81b7bf8914556563087ec6d5def3 (diff) | |
| download | emacs-3e824b05af3a75768a61001fad68e2340af810eb.tar.gz emacs-3e824b05af3a75768a61001fad68e2340af810eb.zip | |
Avoid mapcar in two cases in files.el.
* lisp/files.el (find-file-other-window, find-file-other-frame):
Use mapc instead of mapcar.
Fixes: debbugs:18175
| -rw-r--r-- | lisp/ChangeLog | 3 | ||||
| -rw-r--r-- | lisp/files.el | 10 |
2 files changed, 9 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9e3cedd50a1..f5ad8de3f8c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -3,6 +3,9 @@ | |||
| 3 | * url/url-cookie.el (url-cookie-write-file): Let-bind print-length | 3 | * url/url-cookie.el (url-cookie-write-file): Let-bind print-length |
| 4 | and print-level to nil to avoid writing a garbled list. (Bug#16805) | 4 | and print-level to nil to avoid writing a garbled list. (Bug#16805) |
| 5 | 5 | ||
| 6 | * files.el (find-file-other-window, find-file-other-frame): | ||
| 7 | Use mapc instead of mapcar. (Bug#18175) | ||
| 8 | |||
| 6 | 2015-01-17 Stefan Monnier <monnier@iro.umontreal.ca> | 9 | 2015-01-17 Stefan Monnier <monnier@iro.umontreal.ca> |
| 7 | 10 | ||
| 8 | * emacs-lisp/eieio-core.el (eieio--class-constructor): Rename from | 11 | * emacs-lisp/eieio-core.el (eieio--class-constructor): Rename from |
diff --git a/lisp/files.el b/lisp/files.el index f8318d8a34d..e6d80a9a4dc 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -1489,8 +1489,9 @@ expand wildcards (if any) and visit multiple files." | |||
| 1489 | (if (listp value) | 1489 | (if (listp value) |
| 1490 | (progn | 1490 | (progn |
| 1491 | (setq value (nreverse value)) | 1491 | (setq value (nreverse value)) |
| 1492 | (cons (switch-to-buffer-other-window (car value)) | 1492 | (switch-to-buffer-other-window (car value)) |
| 1493 | (mapcar 'switch-to-buffer (cdr value)))) | 1493 | (mapc 'switch-to-buffer (cdr value)) |
| 1494 | value) | ||
| 1494 | (switch-to-buffer-other-window value)))) | 1495 | (switch-to-buffer-other-window value)))) |
| 1495 | 1496 | ||
| 1496 | (defun find-file-other-frame (filename &optional wildcards) | 1497 | (defun find-file-other-frame (filename &optional wildcards) |
| @@ -1512,8 +1513,9 @@ expand wildcards (if any) and visit multiple files." | |||
| 1512 | (if (listp value) | 1513 | (if (listp value) |
| 1513 | (progn | 1514 | (progn |
| 1514 | (setq value (nreverse value)) | 1515 | (setq value (nreverse value)) |
| 1515 | (cons (switch-to-buffer-other-frame (car value)) | 1516 | (switch-to-buffer-other-frame (car value)) |
| 1516 | (mapcar 'switch-to-buffer (cdr value)))) | 1517 | (mapc 'switch-to-buffer (cdr value)) |
| 1518 | value) | ||
| 1517 | (switch-to-buffer-other-frame value)))) | 1519 | (switch-to-buffer-other-frame value)))) |
| 1518 | 1520 | ||
| 1519 | (defun find-file-existing (filename) | 1521 | (defun find-file-existing (filename) |