From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ralf Angeli Newsgroups: gmane.emacs.bugs Subject: bug#376: latex error message starts dired Date: Fri, 25 Jul 2008 19:50:39 +0200 Message-ID: <87ej5h7t00.fsf@photon.caeruleus.net> References: <878wvpzx2m.fsf@stupidchicken.com> Reply-To: Ralf Angeli , 376@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1217009256 6577 80.91.229.12 (25 Jul 2008 18:07:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 25 Jul 2008 18:07:36 +0000 (UTC) Cc: 376@emacsbugs.donarmstrong.com, Nate Eldredge To: Chong Yidong Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jul 25 20:08:25 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KMRiJ-0001xp-TE for geb-bug-gnu-emacs@m.gmane.org; Fri, 25 Jul 2008 20:08:24 +0200 Original-Received: from localhost ([127.0.0.1]:37743 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KMRhQ-0000Kn-6V for geb-bug-gnu-emacs@m.gmane.org; Fri, 25 Jul 2008 14:07:28 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KMRhL-0000KD-PZ for bug-gnu-emacs@gnu.org; Fri, 25 Jul 2008 14:07:23 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KMRhK-0000Jn-9K for bug-gnu-emacs@gnu.org; Fri, 25 Jul 2008 14:07:23 -0400 Original-Received: from [199.232.76.173] (port=33279 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KMRhJ-0000Jb-Tv for bug-gnu-emacs@gnu.org; Fri, 25 Jul 2008 14:07:21 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:35498) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KMRhJ-00066X-FL for bug-gnu-emacs@gnu.org; Fri, 25 Jul 2008 14:07:21 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m6PI7JLh002924; Fri, 25 Jul 2008 11:07:19 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m6PI04bm032421; Fri, 25 Jul 2008 11:00:04 -0700 X-Loop: don@donarmstrong.com Resent-From: Ralf Angeli Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Fri, 25 Jul 2008 18:00:04 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 376 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 376-submit@emacsbugs.donarmstrong.com id=B376.121700825131109 (code B ref 376); Fri, 25 Jul 2008 18:00:04 +0000 Original-Received: (at 376) by emacsbugs.donarmstrong.com; 25 Jul 2008 17:50:51 +0000 Original-Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.171]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m6PHol2I031103 for <376@emacsbugs.donarmstrong.com>; Fri, 25 Jul 2008 10:50:49 -0700 Original-Received: from photon.caeruleus.net (p54A53B24.dip0.t-ipconnect.de [84.165.59.36]) by mrelayeu.kundenserver.de (node=mrelayeu4) with ESMTP (Nemesis) id 0ML21M-1KMRRA3B5o-0000o0; Fri, 25 Jul 2008 19:50:41 +0200 In-Reply-To: <878wvpzx2m.fsf@stupidchicken.com> (Chong Yidong's message of "Fri, 25 Jul 2008 13:35:13 -0400") X-Provags-ID: V01U2FsdGVkX18O3Tv4DhSaf6YbbR84jg2Vsz057v0sLiffO9S kDC/P1SKIP2a3XnTFK7VOSpiPJozQytosVCpvmhuj8ETcFtDK2 bXG6pvlUWtDnyUE//iWiA== X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) Resent-Date: Fri, 25 Jul 2008 14:07:23 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:18856 Archived-At: * Chong Yidong (2008-07-25) writes: >> The parser finds this error and subsequently tries to determine the file >> name. In course of that it checks the "(\pi" construct with point right >> before the backslash. In this case the form >> (file-readable-p (thing-at-point 'filename)) >> returns t and the file name is set to an empty string. (This is what >> `(thing-at-point 'filename)' returns.) > > How bout the following patch to tex-mode? > ! (while (not > ! (and (setq try-filename (thing-at-point > ! 'filename)) > ! (not (string= "" try-filename)) > ! (file-readable-p try-filename))) Looks okay (without actually trying it). (I'd probably move the `setq' call into the `string=' call.) Of course it will still lose if there is a string after the paren which corresponds to the name of an existing file, but the chances for that are really slim. -- Ralf