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: Re: Font-lock decides function call is function declaration in C+ + - Patch Date: 8 Mar 2007 23:07:56 +0100 Message-ID: <20070308232434.GA4264@muc.de> References: <81CCA6588E60BB42BE68BD029ED4826011AB3F79@wimex2.wim.midas-kapiti.com> <20070223010309.GA3981@muc.de> <87y7mgubia.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1173391702 10942 80.91.229.12 (8 Mar 2007 22:08:22 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 8 Mar 2007 22:08:22 +0000 (UTC) Cc: emacs-devel@gnu.org To: Chong Yidong , "Marshall, Simon" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Mar 08 23:08:15 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 1HPQmT-0004pw-BL for ged-emacs-devel@m.gmane.org; Thu, 08 Mar 2007 23:08:13 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HPQmi-0001QZ-AH for ged-emacs-devel@m.gmane.org; Thu, 08 Mar 2007 17:08:28 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HPQmX-0001QT-V7 for emacs-devel@gnu.org; Thu, 08 Mar 2007 17:08:17 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HPQmV-0001QH-Jv for emacs-devel@gnu.org; Thu, 08 Mar 2007 17:08:16 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HPQmV-0001QE-Cg for emacs-devel@gnu.org; Thu, 08 Mar 2007 17:08:15 -0500 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 1HPQmF-00058u-9D for emacs-devel@gnu.org; Thu, 08 Mar 2007 17:07:59 -0500 Original-Received: (qmail 86081 invoked by uid 3782); 8 Mar 2007 22:07:56 -0000 Original-Received: from acm.muc.de (p54A3E2D3.dip.t-dialin.net [84.163.226.211]) by colin2.muc.de (tmda-ofmipd) with ESMTP; Thu, 08 Mar 2007 23:07:54 +0100 Original-Received: (qmail 4472 invoked by uid 1000); 8 Mar 2007 23:24:34 -0000 Original-Date: Thu, 8 Mar 2007 23:24:34 +0000 Content-Disposition: inline In-Reply-To: <87y7mgubia.fsf@stupidchicken.com> 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:67588 Archived-At: Hi, Chong and Simon On Thu, Mar 01, 2007 at 12:19:57PM -0500, Chong Yidong wrote: > Hi Alan, > Judging by the size of the patch you sent, and the time it's taking to > write it, this seems to be a lot of work. Once we include the time > necessary for testing such a big change, it will probably > significantly delay the Emacs 22 release. int main () { foo <===== type "();", then erase it. bar (); } I've just committed a patch to cc-mode.el and cc-engine.el which fixes Simon's (first) bug. [The "variant" he mentioned is a distinct bug.] It's a fairly scrappy ad-hoc patch - it fixes a particular simple bug scenario which will surely occur frequently. Its idea is to remove tokens from the cache `c-found-types' whenever these tokens are broken up (e.g. by typing stuff in the middle of them, or removing space which separated them from other tokens) or when their syntactic identity as types ceases is disrupted. I think this cache mechanism should to be thought through and either abolished or amended to work consistently. -- Alan Mackenzie (Ittersbach Germany).