From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Werner LEMBERG Newsgroups: gmane.emacs.devel Subject: Re: file variables and man pages with preprocessors Date: Mon, 12 Nov 2007 12:20:43 +0100 (CET) Message-ID: <20071112.122043.247515689.wl@gnu.org> References: <20071112.074510.66409949.wl@gnu.org> <4ed4ufalv8.fsf@fencepost.gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1194866441 28754 80.91.229.12 (12 Nov 2007 11:20:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 12 Nov 2007 11:20:41 +0000 (UTC) Cc: rms@gnu.org, emacs-devel@gnu.org To: rgm@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Nov 12 12:20:45 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1IrXLQ-0001WE-JZ for ged-emacs-devel@m.gmane.org; Mon, 12 Nov 2007 12:20:44 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IrXLE-0006XO-9W for ged-emacs-devel@m.gmane.org; Mon, 12 Nov 2007 06:20:32 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IrXLA-0006WK-Sv for emacs-devel@gnu.org; Mon, 12 Nov 2007 06:20:28 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IrXL9-0006Tq-CY for emacs-devel@gnu.org; Mon, 12 Nov 2007 06:20:28 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IrXL9-0006TX-6x for emacs-devel@gnu.org; Mon, 12 Nov 2007 06:20:27 -0500 Original-Received: from moutng.kundenserver.de ([212.227.126.187]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IrXL0-0006hi-9d; Mon, 12 Nov 2007 06:20:18 -0500 Original-Received: from localhost (ip-62-143-170-169.1211H-CUD12K-04.ish.de [62.143.170.169]) by mrelayeu.kundenserver.de (node=mrelayeu8) with ESMTP (Nemesis) id 0ML31I-1IrXKy3hzt-0003tm; Mon, 12 Nov 2007 12:20:17 +0100 In-Reply-To: <4ed4ufalv8.fsf@fencepost.gnu.org> X-Mailer: Mew version 5.2.50 on Emacs 22.0.97.1 / Mule 5.0 (SAKAKI) X-Provags-ID: V01U2FsdGVkX1/19hg9EgjRBiQl33BPDvKW0yJfddgNs+CWaGk 2EYKhxl941BxwO9lC8zZUmAadjRlwhRwR9pHUj48AiEicsQLDY iUwHfkcpOuFrGgQ9DwuMg== X-detected-kernel: by monty-python.gnu.org: Linux 2.6? (barebone, rare!) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:83041 Archived-At: > > If someone shows me where this should be handled, I'll fix it by > > myself and apply the changes to the CVS. I wasn't able to find > > the location in the sources where the shebang is handled > > w.r.t. recognizing the encoding tag. > > set-auto-mode-1 in files.el Thanks. Here's what I'm planning to commit: --- files.el.old 2007-11-11 14:20:14.000000000 +0100 +++ files.el 2007-11-12 12:19:03.000000000 +0100 @@ -2428,7 +2428,12 @@ ;; put them in the first line of ;; such a file without screwing up ;; the interpreter invocation. - (and (looking-at "^#!") 2)) t) + ;; The same holds for + ;; '\" + ;; in man pages (preprocessor + ;; magic for the `man' program). + (and (or (looking-at "^#!") + (looking-at "^'\\\\\"")) 2)) t) (progn (skip-chars-forward " \t") (setq beg (point)) > If the #! special case is documented in the manuals, the \" one > probably should be too. Yes, will do. Werner