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

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

bug#3418: Issue with compile.el and compilation-parse-errors-filename-fu


From: Gary Oberbrunner
Subject: bug#3418: Issue with compile.el and compilation-parse-errors-filename-function
Date: Fri, 29 May 2009 10:46:51 -0400
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1b3pre) Gecko/20081218 Lightning/1.0pre Shredder/3.0b2pre Mnenhy/0.7.6.0

Hi emacs folks. I submitted a patch to compilation-get-file-structure in compile.el in 2001, introducing this stanza:

        ;; If compilation-parse-errors-filename-function is
        ;; defined, use it to process the filename.
        (when compilation-parse-errors-filename-function
          (setq filename
                (funcall
                         filename)))

At some point since then, the filename was changed to not always be absolute; there's now a variable spec-directory in that function. This means that implementations of compilation-parse-errors-filename-function can't always work correctly since it doesn't know the full path of the file.

I'm happy to work on a fix, but I see a few issues.

Solution 1: add 2nd arg SPEC-DIRECTORY to compilation-parse-errors-filename-function. Problem: existing implementations will get an incorrect number of args error and will have to change.

Solution 2: make filename absolute before passing to compilation-parse-errors-filename-function. Problem: the rest of the code is pretty careful not to absolutize the filename; this would change the behavior in ways I don't completely understand.

Of course I am personally happy with solution 1, but since it affects compatibility I thought I should bring it up on this list. I am not on the list, so please cc me with any replies, thanks!

--
. . . . . . . . . . . . . . . . . . . . . . . . .
Gary Oberbrunner                garyo@genarts.com
GenArts, Inc.                   Tel: 617-492-2888
955 Mass. Ave                   Fax: 617-492-2852
Cambridge, MA 02139 USA         www.genarts.com






reply via email to

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