unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Richard Copley <rcopley@gmail.com>
To: pquessev@gmail.com
Cc: help-gnu-emacs@gnu.org
Subject: Re: Error message not recognized in compilation buffer
Date: Fri, 21 Jun 2019 10:38:18 +0100	[thread overview]
Message-ID: <CAPM58ogthrZEAyih7AMMfV0AJFMjGN5ta+O5v7FE+g2cfTo+AA@mail.gmail.com> (raw)
In-Reply-To: <83r27oyazf.fsf@gmail.com>

On Thu, 20 Jun 2019 at 08:25, Pascal Quesseveur <pquessev@gmail.com> wrote:

    I am using ant under emacs on Windows (version 24.3) to compile Pascal
    source codes with Delphi compiler. When an error occurs it is not
    identified as an error in the compilation buffer. Error message is:

    TestEnum.dpr(24) Error: E2029 ',' or ':' expected but '(' found

    There is a regexp for borland in compilation-error-regexp-alist-alist
    that seems to match the error message but I don't understand how it is
    supposed to work.

    I would be glad if someone could explain the matching of the
    compilation error messages.

Have you already seen the explanation in the docstring for
"compilation-error-regexp-alist"? It might also be useful to look
at the existing regexps (compilation-error-regexp-alist-alist)
the sample file "etc/compilation.txt" in the Emacs distribution.

It turns out there's a note in the sample file that the predefined
regexp for borland is for "Borland C++, C++Builder".

An error specification matching your example might look something
like this:

("^\\([a-zA-Z]?:?[^:() \t\n]+\\)(\\([0-9]+\\)) \
\\(?:Error\\|\\(Warning\\)\\|\\(Hint\\)\\):" 1 2 nil (3 . 4))

Use M-x customize-variable to add it to compilation-error-regexp-alist
making sure to choose 'Error specification', not 'Predefined symbol',
from the Value Menu.


  reply	other threads:[~2019-06-21  9:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-20  7:25 Error message not recognized in compilation buffer Pascal Quesseveur
2019-06-21  9:38 ` Richard Copley [this message]
2019-06-21 10:20   ` Pascal Quesseveur

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAPM58ogthrZEAyih7AMMfV0AJFMjGN5ta+O5v7FE+g2cfTo+AA@mail.gmail.com \
    --to=rcopley@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    --cc=pquessev@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).