diff options
| author | Richard M. Stallman | 1994-07-26 19:18:06 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1994-07-26 19:18:06 +0000 |
| commit | b4300a1a6ca1725bee18f0ce8f2636869341e16e (patch) | |
| tree | e88c647620693b11d11f7876accc2f14b4eb545a | |
| parent | 8bce086749c63d6812a8df1e49592119091379ee (diff) | |
| download | emacs-b4300a1a6ca1725bee18f0ce8f2636869341e16e.tar.gz emacs-b4300a1a6ca1725bee18f0ce8f2636869341e16e.zip | |
(compilation-next-error-locus): New arg SILENT.
| -rw-r--r-- | lisp/progmodes/compile.el | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 607bf06eb55..dd5b3696471 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el | |||
| @@ -819,7 +819,7 @@ See variables `compilation-parse-errors-function' and | |||
| 819 | (consp argp)))) | 819 | (consp argp)))) |
| 820 | ;;;###autoload (define-key ctl-x-map "`" 'next-error) | 820 | ;;;###autoload (define-key ctl-x-map "`" 'next-error) |
| 821 | 821 | ||
| 822 | (defun compilation-next-error-locus (&optional move reparse) | 822 | (defun compilation-next-error-locus (&optional move reparse silent) |
| 823 | "Visit next compilation error and return locus in corresponding source code. | 823 | "Visit next compilation error and return locus in corresponding source code. |
| 824 | This operates on the output from the \\[compile] command. | 824 | This operates on the output from the \\[compile] command. |
| 825 | If all preparsed error messages have been processed, | 825 | If all preparsed error messages have been processed, |
| @@ -832,7 +832,8 @@ marker at the location in the source code indicated by the error message. | |||
| 832 | Optional first arg MOVE says how many error messages to move forwards (or | 832 | Optional first arg MOVE says how many error messages to move forwards (or |
| 833 | backwards, if negative); default is 1. Optional second arg REPARSE, if | 833 | backwards, if negative); default is 1. Optional second arg REPARSE, if |
| 834 | non-nil, says to reparse the error message buffer and reset to the first | 834 | non-nil, says to reparse the error message buffer and reset to the first |
| 835 | error (plus MOVE - 1). | 835 | error (plus MOVE - 1). If optional third argument SILENT is non-nil, return |
| 836 | nil instead of raising an error if there are no more errors. | ||
| 836 | 837 | ||
| 837 | The current buffer should be the desired compilation output buffer." | 838 | The current buffer should be the desired compilation output buffer." |
| 838 | (or move (setq move 1)) | 839 | (or move (setq move 1)) |
| @@ -878,7 +879,7 @@ The current buffer should be the desired compilation output buffer." | |||
| 878 | (get-buffer-process | 879 | (get-buffer-process |
| 879 | (current-buffer))) | 880 | (current-buffer))) |
| 880 | 'run) | 881 | 'run) |
| 881 | " yet")))) | 882 | " yet"))))) |
| 882 | (setq compilation-error-list (cdr next-errors)) | 883 | (setq compilation-error-list (cdr next-errors)) |
| 883 | (if (null (cdr next-error)) | 884 | (if (null (cdr next-error)) |
| 884 | ;; This error is boring. Go to the next. | 885 | ;; This error is boring. Go to the next. |
| @@ -951,7 +952,7 @@ The current buffer should be the desired compilation output buffer." | |||
| 951 | (or (not (markerp (cdr next-error))) | 952 | (or (not (markerp (cdr next-error))) |
| 952 | (not (marker-buffer (cdr next-error)))))) | 953 | (not (marker-buffer (cdr next-error)))))) |
| 953 | (setq next-errors compilation-error-list | 954 | (setq next-errors compilation-error-list |
| 954 | next-error (car next-errors)))) | 955 | next-error (car next-errors))))) |
| 955 | 956 | ||
| 956 | ;; Skip over multiple error messages for the same source location, | 957 | ;; Skip over multiple error messages for the same source location, |
| 957 | ;; so the next C-x ` won't go to an error in the same place. | 958 | ;; so the next C-x ` won't go to an error in the same place. |