This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Emacs and GFortran


   You will need to audit each and every one to ensure that the
   messages meet your expectations.  You'll then need to fix the
   testsuite.

This is not needed, you are exaggerating beyond belief Steve.

Here is another version that is should be backward compatible with the
bits that the testsuite parses.  This will fix the problem the
original user reported; namley allowing programs that parse GNU style
error message to jump to the location of the error/warning.  It is a
simple fix, why can it simply not be applied?

Index: error.c
===================================================================
--- error.c	(revision 117956)
+++ error.c	(working copy)
@@ -134,6 +134,15 @@
 
   lb = loc->lb;
   f = lb->file;
+  /* Allow programs that parse GNU style error message catch the
+     error.  */
+  error_printf ("%s:%d:\n", f->filename,
+#ifdef USE_MAPPED_LOCATION
+		LOCATION_LINE (lb->location)
+#else
+		lb->linenum
+#endif
+		);
   error_printf ("In file %s:%d\n", f->filename,
 #ifdef USE_MAPPED_LOCATION
 		LOCATION_LINE (lb->location)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]