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#13862: 24.3.50; File local-variables error: (error "Local variables entry is missing the prefix") Date: Mon, 04 Mar 2013 18:07:27 +0200 Message-ID: <83lia3tagw.fsf@gnu.org> References: <87bob0794w.fsf@gmail.com> <871ubw78td.fsf@gmail.com> <6jwqto10ig.fsf@fencepost.gnu.org> <87ppzf7s1d.fsf@gmail.com> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1362413338 8766 80.91.229.3 (4 Mar 2013 16:08:58 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 4 Mar 2013 16:08:58 +0000 (UTC) Cc: 13862@debbugs.gnu.org To: Jambunathan K Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Mar 04 17:09:20 2013 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 1UCXwz-00009y-Ei for geb-bug-gnu-emacs@m.gmane.org; Mon, 04 Mar 2013 17:09:17 +0100 Original-Received: from localhost ([::1]:53013 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCXwd-0004Ck-Lo for geb-bug-gnu-emacs@m.gmane.org; Mon, 04 Mar 2013 11:08:55 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:47493) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCXwa-0004BA-1k for bug-gnu-emacs@gnu.org; Mon, 04 Mar 2013 11:08:53 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UCXwV-00058l-A9 for bug-gnu-emacs@gnu.org; Mon, 04 Mar 2013 11:08:51 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:54774) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UCXwV-00058f-76 for bug-gnu-emacs@gnu.org; Mon, 04 Mar 2013 11:08:47 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1UCXwj-0000LG-Pk for bug-gnu-emacs@gnu.org; Mon, 04 Mar 2013 11:09:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 04 Mar 2013 16:09:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13862 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 13862-submit@debbugs.gnu.org id=B13862.13624133031268 (code B ref 13862); Mon, 04 Mar 2013 16:09:01 +0000 Original-Received: (at 13862) by debbugs.gnu.org; 4 Mar 2013 16:08:23 +0000 Original-Received: from localhost ([127.0.0.1]:58883 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UCXw7-0000KP-Gh for submit@debbugs.gnu.org; Mon, 04 Mar 2013 11:08:23 -0500 Original-Received: from mtaout21.012.net.il ([80.179.55.169]:47626) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1UCXw5-0000K9-A3 for 13862@debbugs.gnu.org; Mon, 04 Mar 2013 11:08:22 -0500 Original-Received: from conversion-daemon.a-mtaout21.012.net.il by a-mtaout21.012.net.il (HyperSendmail v2007.08) id <0MJ5007008ML7300@a-mtaout21.012.net.il> for 13862@debbugs.gnu.org; Mon, 04 Mar 2013 18:07:34 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout21.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MJ5007VY8SL7600@a-mtaout21.012.net.il>; Mon, 04 Mar 2013 18:07:34 +0200 (IST) In-reply-to: <87ppzf7s1d.fsf@gmail.com> X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.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:72079 Archived-At: > From: Jambunathan K > Date: Mon, 04 Mar 2013 09:08:54 +0530 > Cc: 13862@debbugs.gnu.org > > Glenn Morris writes: > > > Adding .diff and .patch to inhibit-local-variables-regexps would avoid > > this. > > ,---- > | ;; Local variables: > | ;; generated-autoload-file: "org-loaddefs.el" > | +;; coding: utf-8 > | ;; End: > `---- > > The question is: > > Is there are any local variables in the patch? There isn't any. So why > should we inhibit something that is not there. > > If `diff-mode' has no comment syntax defined, then by extension, it > cannot specify file local variables. File local variables never had anything to do with comment syntax; you won't find that neither in the code nor in the documentation. Which is a Good Thing: if file local variables were supported only for modes which have comment syntax defined, we couldn't have used them in all the modes that don't. For example, Text mode, or the tutorials, or the ChangeLog files. You name it. In modes that do have comment syntax defined, it makes sense to put these variables into comments, so as not to confuse the translator. But that's about all these variables have in common with comments. You will see in the code that Emacs deduces the prefix and suffix heuristically, and that is how this is documented. So I think Glenn is right about the solution. Diffs don't have contents of their own (well, except for the hunk headers), so looking up diffs for file-local variables doesn't make much sense. > ps: I am not sure why *.patch files are visited in diff-mode? What else?