(compilation-parse-errors): Don't store the beginning of the line
containing the end of the error-regexp match. Instead, store the beginning
of the line containing the start of the match, unless the match starts
with a newline, in which case the beginning of the next line.
(compilation-error-regexp-alist): Doc fix: optional cdrs give
string containing %s to produce the file name from the matched text.
(compilation-find-file): Reorder args: MARKER first, then FILENAME, DIR,
and new arg &rest FORMATS (as they appear in parsed the fileinfo lists).
Try each of the FORMATS in each directory tried.
(compilation-next-error-locus): Apply compilation-find-file to the FILEINFO
list.
(compilation-parse-errors): Instead of a cons (DIR . FILE), make a list
(FILE DIR [FORMATS...]) using the 4th cdr of the matching elt of
regexp-alist.
compilation-mode major mode, rather than internal state variables. Don't
want to match a buffer that was once in compilation-minor-mode but is not now.
(compilation-error-regexp-alist): Make first regexp match column numbers too.
Remove regexp for "prog:file:line: error".
Replace GNAT 1.82 regexp with "prog: file:line\(:col\)?: error".
(compilation-parse-errors): If spec has a column subexpr, but it was
optional and didn't match, ignore it.
broken out from compile-internal.
Don't change window height if it is the frame root window.
(compile-internal): Call it.
(compilation-goto-locus): Call it.
Use any visible frame already showing the compilation buffer.
Test only its nilness.
(compile-goto-error): Pass (consp ARGP) to compile-reinitialize-errors
instead of ARGP itself.
(next-error): Code broken out into two new functions; call them.
(compilation-next-error-locus): New function; bulk of code from next-error.
Silently skip errors whose source loci are markers in killed buffers.
(compilation-goto-locus): New function, final code from next-error.
Element lists can now contain a 4th elt giving subexpr for the column.
(next-error): Handle error records with column numbers.
(compilation-parse-errors): Parse column numbers when the alist elt
specifies it. Use string-to-int instead of read for numbers from buffer
text.
absolute file names culled from error msgs.
(compile-abbreviate-directory): Prepend comint-file-name-prefix (if boundp)
to DIR before other processing.
(compilation-forget-errors): Reset compilation-parsing-end to 1 here.
(compile-reinitialize-errors): Don't reset compilation-parsing-end after
calling compilation-forget-errors.
Comment out gratuitous switch-to-buffer call; what was the rationale for it?
Don't check compilation-parsing-end (removed local AT-START); instead
always append to compilation-old-error-list, it will be nil if at start.
If compilation-error-list is non-nil before calling the parser, restore its
previous value afterwards; it still indicates the current error position.
Subtract the length of the existing compilation-error-list from
FIND-AT-LEAST when calling the parser.
(compilation-parse-errors): Don't check LIMIT-SEARCH at end of loop.
Inside check it inside each case of the cond; in error case we must discard
the last new error before stopping (just as for FIND-AT-LEAST).
Use floating-point in buffer percentage calculation, to avoid integer
overflow.
FILE) if it's not a marker. The conversion to using a string containing an
expanded file name was never finished, and anyway it utterly broke
compilation-search-path and few other things.
(next-error): Expect them that way.
(compilation-parse-errors): Make them that way.
(compile-file-of-error): Function removed.
(compilation-error-filedata, compilation-error-filedata-file-name): New
defsubsts.
(compilation-next-file): Use them instead of compile-file-of-error.
generated a marker for the source position of an error message,
store (FILENAME . LINE-NUMBER), not ((DIRECTORY . FILE)
LINE-NUMBER). Doc fix.
(next-error, compilation-parse-errors): Adjusted appropriately.
(compilation-minor-mode): New defvar.
(compilation-minor-mode-map): New defvar; keymap with the bindings
from compilation-mode-map except SPC and DEL.
(compilation-mode-map): Construct this keymap to inherit from
compilation-minor-mode-map.
(compilation-setup): New function, code broken out of compilation-mode.
(compilation-mode): Call it.
(compilation-minor-mode): New function to toggle
compilation-minor-mode; if setting it, call compilation-setup.
GNU format regexp: just allowing blanks to terminate the line number
makes that one handle the HP case. Merged MIPS RISC CC regexp with
Apollo cc regexp: make "s optional, and don't anchor to bol.
compilation-directory-stack to nil; no need to loop through it.
(next-error): For a non-numeric prefix arg, pass nil for
compile-reinitialize-errors's FIND-AT-LEAST arg.
(next-error): When getting marker for error source location, be
sure to examine buffer local value of compilation-old-error-list
before switching to source file buffer.
BSD/GNU regexp to insist that line number end with a colon or
close-paren.
* compile.el (compilation-error-regexp-alist): Add regexp for the
MIPS CC distributed with Ultrix.
looking-at call doesn't clobber its value when we want to use it to back up
before the error we discard.
Make sure compilation-error-list is at least two elts long before checking
its first two elts for being in the same file.