From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#3418: Issue with compile.el and compilation-parse-errors-filename-function Date: Tue, 26 Jan 2016 16:42:58 +0200 Message-ID: <83vb6g1jwt.fsf@gnu.org> References: <4A1FF55B.4040202@genarts.com> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1453819402 24805 80.91.229.3 (26 Jan 2016 14:43:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 26 Jan 2016 14:43:22 +0000 (UTC) Cc: 3418@debbugs.gnu.org, garyo@genarts.com To: Andrew Hyatt Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Jan 26 15:43:11 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aO4pq-0000Ah-LG for geb-bug-gnu-emacs@m.gmane.org; Tue, 26 Jan 2016 15:43:10 +0100 Original-Received: from localhost ([::1]:44495 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aO4pq-0004I6-0Q for geb-bug-gnu-emacs@m.gmane.org; Tue, 26 Jan 2016 09:43:10 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49538) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aO4pm-0004I0-DU for bug-gnu-emacs@gnu.org; Tue, 26 Jan 2016 09:43:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aO4pi-0005BV-Dg for bug-gnu-emacs@gnu.org; Tue, 26 Jan 2016 09:43:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48516) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aO4pi-0005BR-9p for bug-gnu-emacs@gnu.org; Tue, 26 Jan 2016 09:43:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aO4pi-00084l-5Y for bug-gnu-emacs@gnu.org; Tue, 26 Jan 2016 09:43:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 26 Jan 2016 14:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 3418 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 3418-submit@debbugs.gnu.org id=B3418.145381936131015 (code B ref 3418); Tue, 26 Jan 2016 14:43:02 +0000 Original-Received: (at 3418) by debbugs.gnu.org; 26 Jan 2016 14:42:41 +0000 Original-Received: from localhost ([127.0.0.1]:36736 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aO4pM-00084B-Ql for submit@debbugs.gnu.org; Tue, 26 Jan 2016 09:42:41 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:58461) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aO4pL-00083y-TO for 3418@debbugs.gnu.org; Tue, 26 Jan 2016 09:42:40 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aO4pC-00058F-T8 for 3418@debbugs.gnu.org; Tue, 26 Jan 2016 09:42:34 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:37295) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aO4pC-00058B-PW; Tue, 26 Jan 2016 09:42:30 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1326 helo=HOME-C4E4A596F7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1aO4pC-0007I3-3F; Tue, 26 Jan 2016 09:42:30 -0500 In-reply-to: (message from Andrew Hyatt on Tue, 26 Jan 2016 00:21:51 -0500) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:111987 Archived-At: > From: Andrew Hyatt > Date: Tue, 26 Jan 2016 00:21:51 -0500 > Cc: 3418@debbugs.gnu.org > > Gary Oberbrunner writes: > > > 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! > > Sadly, this bug hasn't been responded to. Your description is pretty > code-intensive, for those of us not familiar with the internals, can you > give instructions on how to reproduce a user-visible issue? FWIW, I don't see why not adopt Soution 1, just make the second argument optional. That would be backward-compatible, IIUC.