From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Shell-script mode: Backslash has syntax "punctuation", not "escape". Date: Tue, 3 Jul 2007 11:15:08 +0100 Message-ID: <20070703101508.GA2304@muc.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1183452569 15055 80.91.229.12 (3 Jul 2007 08:49:29 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 3 Jul 2007 08:49:29 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jul 03 10:49:28 2007 connect(): Connection refused 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 1I5e4d-0005L4-69 for ged-emacs-devel@m.gmane.org; Tue, 03 Jul 2007 10:49:27 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I5e4c-000876-P1 for ged-emacs-devel@m.gmane.org; Tue, 03 Jul 2007 04:49:26 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I5e30-00067O-Fo for emacs-devel@gnu.org; Tue, 03 Jul 2007 04:47:46 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I5e2z-00066z-OD for emacs-devel@gnu.org; Tue, 03 Jul 2007 04:47:45 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I5e2z-00066u-HH for emacs-devel@gnu.org; Tue, 03 Jul 2007 04:47:45 -0400 Original-Received: from colin.muc.de ([193.149.48.1] helo=mail.muc.de) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1I5e2y-0004k5-Po for emacs-devel@gnu.org; Tue, 03 Jul 2007 04:47:45 -0400 Original-Received: (qmail 66760 invoked by uid 3782); 3 Jul 2007 08:47:40 -0000 Original-Received: from acm.muc.de (p54A3D27E.dip.t-dialin.net [84.163.210.126]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Tue, 03 Jul 2007 10:47:38 +0200 Original-Received: (qmail 2492 invoked by uid 1000); 3 Jul 2007 10:15:08 -0000 Content-Disposition: inline User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) X-Primary-Address: acm@muc.de X-detected-kernel: FreeBSD 4.6-4.9 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:74230 Archived-At: Hi, Emacs! Load the following file into Emacs: ######################################################################### #!/bin/bash echo Backslash doesn\'t have escape syntax. # The rest of the file now has string fontification. ######################################################################### Font locking doesn't take the backslash in "doesn\'t" seriously. A quick C-u C-x = on this backslash shows it has "." (punctuation) syntax. In Emacs 21, backslash has "\\" (escape) syntax, and this fragment fontifies properly there. Not giving backslash escape syntax seems wierd, so wierd that it was surely done deliberately for a good reason. Can anybody tell me what this reason was? Whatever, it would seem that the Font Locking in this mode needs fixing. -- Alan Mackenzie (Ittersbach, Germany).