diff options
| author | Juri Linkov | 2018-02-27 23:38:04 +0200 |
|---|---|---|
| committer | Juri Linkov | 2018-02-27 23:38:04 +0200 |
| commit | 450b0d1c0dabc2a9f4a5e63db87590e9681b9319 (patch) | |
| tree | 3f619ef16b4fc5edbf3da334f28c744694b1dcd7 | |
| parent | d56b8fa3296c5b1b7abe6cc4048142949a64ac02 (diff) | |
| download | emacs-450b0d1c0dabc2a9f4a5e63db87590e9681b9319.tar.gz emacs-450b0d1c0dabc2a9f4a5e63db87590e9681b9319.zip | |
* lisp/simple.el (next-error-find-buffer-function): Set default to #'ignore.
(next-error-find-buffer): Don't check next-error-find-buffer-function
for nil. (Bug#20489)
| -rw-r--r-- | lisp/simple.el | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lisp/simple.el b/lisp/simple.el index 2101cfe8333..edcb73ce2e1 100644 --- a/lisp/simple.el +++ b/lisp/simple.el | |||
| @@ -170,11 +170,11 @@ rejected, and the function returns nil." | |||
| 170 | (and extra-test-inclusive | 170 | (and extra-test-inclusive |
| 171 | (funcall extra-test-inclusive)))))) | 171 | (funcall extra-test-inclusive)))))) |
| 172 | 172 | ||
| 173 | (defcustom next-error-find-buffer-function nil | 173 | (defcustom next-error-find-buffer-function #'ignore |
| 174 | "Function called to find a `next-error' capable buffer." | 174 | "Function called to find a `next-error' capable buffer." |
| 175 | :type '(choice (const :tag "Single next-error capable buffer on selected frame" | 175 | :type '(choice (const :tag "Single next-error capable buffer on selected frame" |
| 176 | next-error-buffer-on-selected-frame) | 176 | next-error-buffer-on-selected-frame) |
| 177 | (const :tag "No default" nil) | 177 | (const :tag "No default" ignore) |
| 178 | (function :tag "Other function")) | 178 | (function :tag "Other function")) |
| 179 | :group 'next-error | 179 | :group 'next-error |
| 180 | :version "27.1") | 180 | :version "27.1") |
| @@ -212,10 +212,9 @@ that would normally be considered usable. If it returns nil, | |||
| 212 | that buffer is rejected." | 212 | that buffer is rejected." |
| 213 | (or | 213 | (or |
| 214 | ;; 1. If a customizable function returns a buffer, use it. | 214 | ;; 1. If a customizable function returns a buffer, use it. |
| 215 | (when next-error-find-buffer-function | 215 | (funcall next-error-find-buffer-function avoid-current |
| 216 | (funcall next-error-find-buffer-function avoid-current | 216 | extra-test-inclusive |
| 217 | extra-test-inclusive | 217 | extra-test-exclusive) |
| 218 | extra-test-exclusive)) | ||
| 219 | ;; 2. If next-error-last-buffer is an acceptable buffer, use that. | 218 | ;; 2. If next-error-last-buffer is an acceptable buffer, use that. |
| 220 | (if (and next-error-last-buffer | 219 | (if (and next-error-last-buffer |
| 221 | (next-error-buffer-p next-error-last-buffer avoid-current | 220 | (next-error-buffer-p next-error-last-buffer avoid-current |