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-syntactic-keywords obsolet? Date: Sun, 19 Jun 2016 14:59:34 +0000 Message-ID: <20160619145934.GC5875@acm.fritz.box> References: <57627D13.5090008@online.de> <5764F25B.4010204@online.de> <20160618171249.GA5796@acm.fritz.box> <20160619133143.GA5875@acm.fritz.box> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1466348387 15010 80.91.229.3 (19 Jun 2016 14:59:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 19 Jun 2016 14:59:47 +0000 (UTC) Cc: Noam Postavsky , emacs-devel@gnu.org To: Dmitry Gutov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Jun 19 16:59:38 2016 Return-path: Envelope-to: ged-emacs-devel@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 1bEeCH-00062a-SC for ged-emacs-devel@m.gmane.org; Sun, 19 Jun 2016 16:59:38 +0200 Original-Received: from localhost ([::1]:38965 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEeCG-0004mZ-Sc for ged-emacs-devel@m.gmane.org; Sun, 19 Jun 2016 10:59:36 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34920) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEeCA-0004m1-Fw for emacs-devel@gnu.org; Sun, 19 Jun 2016 10:59:31 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bEeC6-0001aj-B9 for emacs-devel@gnu.org; Sun, 19 Jun 2016 10:59:29 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:39552) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bEeC6-0001aE-1G for emacs-devel@gnu.org; Sun, 19 Jun 2016 10:59:26 -0400 Original-Received: (qmail 85935 invoked by uid 3782); 19 Jun 2016 14:59:21 -0000 Original-Received: from acm.muc.de (p4FC46D0C.dip0.t-ipconnect.de [79.196.109.12]) by colin.muc.de (tmda-ofmipd) with ESMTP; Sun, 19 Jun 2016 16:59:19 +0200 Original-Received: (qmail 7667 invoked by uid 1000); 19 Jun 2016 14:59:34 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x X-Received-From: 193.149.48.3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:204513 Archived-At: Hello, Dmitry. On Sun, Jun 19, 2016 at 04:48:05PM +0300, Dmitry Gutov wrote: > On 06/19/2016 04:31 PM, Alan Mackenzie wrote: > > Simply because these scans are done on the change region of > > before/after-change-functions (as expanded), not on the entire tail of > > the buffer. In CC Mode, all the uses of the syntax-table property are > > "local"; a buffer change in an earlier part of the buffer (aside from > > crude syntactic things like inserting unclosed comment/string > > delimiters) cannot affect the properties on the current part of the > > buffer. > So if I remove a closing brace somewhere near the beginning of the > buffer, it still can't affect text properties near the end? No, it can't. If you remove (from a C++ buffer) a terminating template delimiter (">"), that will have the effect of removing the syntax-table text property from its former matching opener ("<"). > If so, what if I remove a closing double-quote instead? Good question. I put printf's (in effect) into the three routines which can expand the scanning region in the after-change-function, and removing a closing double-quote doesn't cause that region to be expanded beyond the current line. -- Alan Mackenzie (Nuremberg, Germany).