[Top][All Lists]

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

Re: Emacs and GFortran

From: Nick Roberts
Subject: Re: Emacs and GFortran
Date: Tue, 31 Oct 2006 10:16:14 +1300

Angelo Graziosi writes:
 > Tobias Burnus wrote:
 > > By the way, g95 has the same problem.
 > Adding
 > (eval-after-load "compile"
 >    '(setq compilation-error-regexp-alist
 >        (cons '("^In file \\(.+\\):\\([0-9]+\\)" 1 2)
 >           compilation-error-regexp-alist)))
 > in .emacs solves it.

The original error message you posted had column number information in the
error output too:

   gfortran hello.F
    In file hello.F:3

         write(*,) 'Hello!'                                                
   Error: Syntax error in WRITE statement at (1)

it would be nice to be able to use this too.  I think gcc outputs kind of
information as something like:

hello.c:3:13: error: blah, blah, blah...

Emacs can then place the cursor in the relevant column when visiting an error
(and Vim probably does something similar too).

Regardless of whose issue it is, it would seem a good idea to co-ordinate
between projects (gfortan/gcc/emacs/vim...).

Nick                                           http://www.inet.net.nz/~nickrob

reply via email to

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