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

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

compile.el - Filename function not called in certain cases


From: Akshay Dua
Subject: compile.el - Filename function not called in certain cases
Date: Wed, 17 Aug 2005 14:25:41 -0700 (PDT)

This bug report will be sent to the Free Software
Foundation,
not to your local site managers!
Please write in English, because the Emacs maintainers
do not have
translators to read other languages for them.

Your bug report will be posted to the
bug-gnu-emacs@gnu.org mailing list,
and to the gnu.emacs.bug news group.

In GNU Emacs 21.2.1 (i686-pc-cygwin, X toolkit)
 of 2004-03-22 on cm-test
configured using `configure  --prefix=/usr
--bindir=/usr/bin --sysconfdir=/etc
--libexecdir=/usr/sbin --localstatedir=/var
--datadir=/usr/share --infodir=/usr/share/info
--mandir=/usr/share/man --without-toolkit-scroll-bars'
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: nil
  locale-coding-system: nil
  default-enable-multibyte-characters: t

Please describe exactly what actions triggered the bug
and the precise symptoms of the bug:

If set, the
'compilation-parse-errors-filename-function'
is called by compile.el for customized file name 
processing. However, this function does not get called
for non-error messages returned by the compiler.
Specifically, 
the ones that are not associated with filenames 
directly but are still used to extract directory paths
etc. 
In this situation, emacs does not understand those
paths 
and vomits an error. Here is the applied patch:

--- compile.old.el      2005-08-17 14:09:42.321651400 -0700
+++ compile.el  2005-08-17 13:36:14.225262500 -0700
@@ -1979,6 +1979,14 @@
                (if (eq type `file)     ; Change current file.
                    (and filename (setq compilation-current-file
filename))
 
+
+                 ;; If compilation-parse-errors-filename-function
is
+                 ;; defined, use it to process the filename.
+                 (when compilation-parse-errors-filename-function
+                   (setq filename
+                         (funcall
compilation-parse-errors-filename-function
+                                  filename)))
+
                  ;; Enter or leave directory.
                  (setq stack compilation-directory-stack)
                  (and filename


Thanks to Gleb Arshinov who helped me with this fix.

Recent input:
M-x r e p o r t <tab> <return>

Recent messages:
Loading advice...done
(my-to-cygpath c:/test/path/file.cpp)
 ->/cygdrive/c/test/path/file.cpp
(my-to-cygpath )
 ->
Loading mwheel...done
Loading ring...done
For information about the GNU Project and its goals,
type C-h C-p.
Loading cc-mode...done
Loading emacsbug...done





reply via email to

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