unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
[parent not found: <mailman.735.1061576911.29551.bug-gnu-emacs@gnu.org>]
* next-error accepts a prefix argument, but previous-error doesn't
@ 2003-08-19 17:31 Kevin Rodgers
  0 siblings, 0 replies; 4+ messages in thread
From: Kevin Rodgers @ 2003-08-19 17:31 UTC (permalink / raw)


Here's a patch to allow the user to specify how many errors to move:

*** emacs-21.3/lisp/progmodes/compile.el.orig	Fri Jan 17 06:45:11 2003
--- emacs-21.3/lisp/progmodes/compile.el	Tue Aug 19 11:26:38 2003
***************
*** 1478,1489 ****
   			   (consp argp))))
   ;;;###autoload (define-key ctl-x-map "`" 'next-error)

! (defun previous-error ()
     "Visit previous compilation error message and corresponding source code.
- This operates on the output from the \\[compile] command."
-   (interactive)
-   (next-error -1))

   (defun first-error ()
     "Reparse the error message buffer and start at the first error.
   Visit corresponding source code.
--- 1478,1493 ----
   			   (consp argp))))
   ;;;###autoload (define-key ctl-x-map "`" 'next-error)

! (defun previous-error (argp)
     "Visit previous compilation error message and corresponding source code.

+ A prefix ARGP specifies how many error messages to move;
+ negative means move forward to next error messages.
+
+ This operates on the output from the \\[compile] and \\[grep] commands."
+   (interactive "P")
+   (next-error (- (prefix-numeric-value argp))))
+
   (defun first-error ()
     "Reparse the error message buffer and start at the first error.
   Visit corresponding source code.

-- 
Kevin Rodgers

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2003-08-22 23:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.585.1061451450.29551.bug-gnu-emacs@gnu.org>
2003-08-21 15:51 ` next-error accepts a prefix argument, but previous-error doesn't Juri Linkov
2003-08-22 17:43   ` Kevin Rodgers
     [not found] <mailman.735.1061576911.29551.bug-gnu-emacs@gnu.org>
2003-08-22 23:05 ` Juri Linkov
2003-08-19 17:31 Kevin Rodgers

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).