From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#3269: 23.0.93; C-mode text highlighting Date: Mon, 18 May 2009 21:30:30 +0000 Message-ID: <20090518213030.GD12920__20530.980724334$1242683538$gmane$org@muc.de> References: <878wl1h5fw.fsf@ancient.thomaschristensen.org> <20090514213924.GB2413@muc.de> <20090518150643.GA12920@muc.de> Reply-To: Alan Mackenzie , 3269@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 1242683538 29292 80.91.229.12 (18 May 2009 21:52:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 18 May 2009 21:52:18 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org, Chong Yidong , 3269@emacsbugs.donarmstrong.com, Thomas Christensen , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon May 18 23:52:10 2009 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 1M6Akk-0007Cv-EB for geb-bug-gnu-emacs@m.gmane.org; Mon, 18 May 2009 23:52:10 +0200 Original-Received: from localhost ([127.0.0.1]:49400 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1M6Akj-0004re-Ji for geb-bug-gnu-emacs@m.gmane.org; Mon, 18 May 2009 17:52:09 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1M6Akf-0004qy-Tx for bug-gnu-emacs@gnu.org; Mon, 18 May 2009 17:52:06 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1M6Akb-0004nY-4w for bug-gnu-emacs@gnu.org; Mon, 18 May 2009 17:52:05 -0400 Original-Received: from [199.232.76.173] (port=35033 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1M6Aka-0004nU-PA for bug-gnu-emacs@gnu.org; Mon, 18 May 2009 17:52:00 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:46566) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1M6Aka-0007lR-5t for bug-gnu-emacs@gnu.org; Mon, 18 May 2009 17:52:00 -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 n4ILpu1G007757; Mon, 18 May 2009 14:51:57 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id n4ILZ3BG002364; Mon, 18 May 2009 14:35:03 -0700 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Alan Mackenzie Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Mon, 18 May 2009 21:35:03 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 3269 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.1242682196859 (code B ref -1); Mon, 18 May 2009 21:35:03 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 18 May 2009 21:29:56 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id n4ILTqQO000846 for ; Mon, 18 May 2009 14:29:53 -0700 Original-Received: from mail.gnu.org ([199.232.76.166]:49869 helo=mx10.gnu.org) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1M6AP9-0005CG-Ro for emacs-pretest-bug@gnu.org; Mon, 18 May 2009 17:29:51 -0400 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1M6AP8-0004wI-5W for emacs-pretest-bug@gnu.org; Mon, 18 May 2009 17:29:51 -0400 Original-Received: from colin.muc.de ([193.149.48.1]:4255 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 1M6AP7-0004w0-M3 for emacs-pretest-bug@gnu.org; Mon, 18 May 2009 17:29:50 -0400 Original-Received: (qmail 50159 invoked by uid 3782); 18 May 2009 21:29:47 -0000 Original-Received: from acm.muc.de (pD9E22FAC.dip.t-dialin.net [217.226.47.172]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Mon, 18 May 2009 23:29:45 +0200 Original-Received: (qmail 21937 invoked by uid 1000); 18 May 2009 21:30:30 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i X-Delivery-Agent: TMDA/1.1.5 (Fettercairn) X-Primary-Address: acm@muc.de X-detected-operating-system: by monty-python.gnu.org: FreeBSD 4.6-4.9 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Mon, 18 May 2009 17:52:05 -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:27993 Archived-At: Hi, Stefan! On Mon, May 18, 2009 at 03:53:42PM -0400, Stefan Monnier wrote: > > OK, here is a patch for half of the problem - it now fontifies a broken > > string in a #define properly > For some definition of "properly". The opening string quote (?\" or ?\') gets f-l-warning-face. The rest of the unclosed string (up to the first EOL which isn't escaped) gets f-l-string-face. Actually, that's not _quite_ "proper". A string with an even number of backslashes at an EOL is broken at that point, but the font locking doesn't show this (yet). I don't suppose that will bother you all that much. ;-) > > The second half of the problem is to fix it so that you don't have to > > type M-o M-o afterwards. Any change you'll let me do this before > > this week's pretest, Yidong? > I think this part is more important. I don't care much (if at all) > about how invalid code is highlighted. I agree it's important. I've got it working; what's more, the code doesn't advise any of the font lock functions for (>= emacs-major-version 22). I'll commit it tomorrow sometime. > Stefan -- Alan Mackenzie (Nuremberg, Germany).