aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuri Linkov2004-09-01 16:19:04 +0000
committerJuri Linkov2004-09-01 16:19:04 +0000
commit310abb0b815e22977e87685855fbccdd7e329bba (patch)
treeb7c1881262183d60f860eb5bc8389824177ca44b
parent7d01236c2247fe2e499ed6c1759acfb0dfe04570 (diff)
downloademacs-310abb0b815e22977e87685855fbccdd7e329bba.tar.gz
emacs-310abb0b815e22977e87685855fbccdd7e329bba.zip
(next-error, previous-error, first-error)
(next-error-no-select, previous-error-no-select): Make arguments optional.
-rw-r--r--lisp/simple.el14
1 files changed, 7 insertions, 7 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index 78ca8e63f2e..32eecec8d4b 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -135,7 +135,7 @@ to navigate in it.")
135 (current-buffer))) 135 (current-buffer)))
136 (error "No next-error capable buffer found")))))))) 136 (error "No next-error capable buffer found"))))))))
137 137
138(defun next-error (arg &optional reset) 138(defun next-error (&optional arg reset)
139 "Visit next next-error message and corresponding source code. 139 "Visit next next-error message and corresponding source code.
140 140
141If all the error messages parsed so far have been processed already, 141If all the error messages parsed so far have been processed already,
@@ -175,7 +175,7 @@ See variables `compilation-parse-errors-function' and
175 175
176(define-key ctl-x-map "`" 'next-error) 176(define-key ctl-x-map "`" 'next-error)
177 177
178(defun previous-error (n) 178(defun previous-error (&optional n)
179 "Visit previous next-error message and corresponding source code. 179 "Visit previous next-error message and corresponding source code.
180 180
181Prefix arg N says how many error messages to move backwards (or 181Prefix arg N says how many error messages to move backwards (or
@@ -183,9 +183,9 @@ forwards, if negative).
183 183
184This operates on the output from the \\[compile] and \\[grep] commands." 184This operates on the output from the \\[compile] and \\[grep] commands."
185 (interactive "p") 185 (interactive "p")
186 (next-error (- n))) 186 (next-error (- (or n 1))))
187 187
188(defun first-error (n) 188(defun first-error (&optional n)
189 "Restart at the first error. 189 "Restart at the first error.
190Visit corresponding source code. 190Visit corresponding source code.
191With prefix arg N, visit the source code of the Nth error. 191With prefix arg N, visit the source code of the Nth error.
@@ -193,7 +193,7 @@ This operates on the output from the \\[compile] command, for instance."
193 (interactive "p") 193 (interactive "p")
194 (next-error n t)) 194 (next-error n t))
195 195
196(defun next-error-no-select (n) 196(defun next-error-no-select (&optional n)
197 "Move point to the next error in the next-error buffer and highlight match. 197 "Move point to the next error in the next-error buffer and highlight match.
198Prefix arg N says how many error messages to move forwards (or 198Prefix arg N says how many error messages to move forwards (or
199backwards, if negative). 199backwards, if negative).
@@ -203,14 +203,14 @@ select the source buffer."
203 (next-error n) 203 (next-error n)
204 (pop-to-buffer next-error-last-buffer)) 204 (pop-to-buffer next-error-last-buffer))
205 205
206(defun previous-error-no-select (n) 206(defun previous-error-no-select (&optional n)
207 "Move point to the previous error in the next-error buffer and highlight match. 207 "Move point to the previous error in the next-error buffer and highlight match.
208Prefix arg N says how many error messages to move backwards (or 208Prefix arg N says how many error messages to move backwards (or
209forwards, if negative). 209forwards, if negative).
210Finds and highlights the source line like \\[previous-error], but does not 210Finds and highlights the source line like \\[previous-error], but does not
211select the source buffer." 211select the source buffer."
212 (interactive "p") 212 (interactive "p")
213 (next-error-no-select (- n))) 213 (next-error-no-select (- (or n 1))))
214 214
215;;; 215;;;
216 216