bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#13335: 24.1; compilation misparses GNU-style message locations


From: Mattias Engdegård
Subject: bug#13335: 24.1; compilation misparses GNU-style message locations
Date: Wed, 2 Jan 2013 15:53:19 +0100

According to the GNU standards, a valid error message format is

FILE:LINE.COL1-COL2: MESSAGE

but this is not parsed correctly by the "gnu" regexp in compile.el;
it is interpreted as the line range LINE-COL2 starting at column COL1.
The consequence is that Emacs does not highlight the correct part of the
buffer when entering the file at that location.

This was disovered when writing a tool whose diagnostics would work
nicely with Emacs. Using the longer form

FILE:LINE.COL1-LINE.COL2: TEXT

worked correctly. According to etc/compilation.txt, it looks like the
intention is to allow either format.

The "gnu" regexp is quite complex and it is not immediately obvious
what is wrong. There is also what appears to be a superfluous backslash
on the last line:

 *[Ee]rror\\|\[0-9]?\\(?:[^0-9\n]\\|$\\)\\|[0-9][0-9][0-9]\\)"
             ^
Since "\[" just means "[", this does not affect the actual regexp.

In GNU Emacs 24.1.1 (x86_64-unknown-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2012-07-30 on bach.e.vtech






reply via email to

[Prev in Thread] Current Thread [Next in Thread]