From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Unbalanced change hooks (part 2) [Documentation fix still remaining] Date: Tue, 30 Aug 2016 08:56:05 -0400 Message-ID: References: <20160810185735.GD3413@acm.fritz.box> <20160811112951.GA2154@acm.fritz.box> <7e1478b6-cf00-fcbf-8c24-43bdaa57e2b6@dancol.org> <415d1cca-f32c-624e-a4be-9aadcf8a0f17@dancol.org> <83inujbpek.fsf@gnu.org> <83eg57bl8f.fsf@gnu.org> <5ee6ff4a-2d58-82f1-8e83-479c62f0b729@dancol.org> <837fazbjb4.fsf@gnu.org> <75100b15-d49f-5a1a-d73b-24db77c891bf@dancol.org> <831t17bged.fsf@gnu.org> <83shtn9e0z.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1472561813 13833 195.159.176.226 (30 Aug 2016 12:56:53 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 30 Aug 2016 12:56:53 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) Cc: dancol@dancol.org, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 30 14:56:49 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1beiau-00039w-5f for ged-emacs-devel@m.gmane.org; Tue, 30 Aug 2016 14:56:48 +0200 Original-Received: from localhost ([::1]:49024 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1beiar-0005rQ-Ju for ged-emacs-devel@m.gmane.org; Tue, 30 Aug 2016 08:56:45 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53589) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1beiaM-0005rA-Im for emacs-devel@gnu.org; Tue, 30 Aug 2016 08:56:15 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1beiaK-00067Z-PU for emacs-devel@gnu.org; Tue, 30 Aug 2016 08:56:13 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:8606) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1beiaE-00066d-0i; Tue, 30 Aug 2016 08:56:06 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A0CXFACJI6tX/2V2oWxdHAEBgyeES4VQsF2BfYYXBAICgV06EwEBAQEBAQFdJ4RfAQEDAVYjEAs0EhQYDSSIPAjBXAEBCAIlineJfh0BBJk8mFmFfI5wgTwgAzGEFiCHXgEBAQ X-IPAS-Result: A0CXFACJI6tX/2V2oWxdHAEBgyeES4VQsF2BfYYXBAICgV06EwEBAQEBAQFdJ4RfAQEDAVYjEAs0EhQYDSSIPAjBXAEBCAIlineJfh0BBJk8mFmFfI5wgTwgAzGEFiCHXgEBAQ X-IronPort-AV: E=Sophos;i="5.28,500,1464667200"; d="scan'208";a="269792105" Original-Received: from 108-161-118-101.dsl.teksavvy.com (HELO pastel.home) ([108.161.118.101]) by smtp.teksavvy.com with ESMTP; 30 Aug 2016 08:56:06 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 0BCD65FC80; Tue, 30 Aug 2016 08:56:05 -0400 (EDT) In-Reply-To: <83shtn9e0z.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 30 Aug 2016 05:38:52 +0300") X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 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:206927 Archived-At: >> The optimization is beside the point: not calling b-c-f in some corner >> case breaks the entire model because a user such as syntax-ppss relies >> on b-c-f to know when to flush its cache, so if you don't call it when >> the buffer is modified, the cache ends up stale. > I'm saying that flushing the entire cache in that case is not a > problem, it's what needs to be done anyway. The problem is that b-c-f is not called at all, so syntax-ppss doesn't know that it should flush (any part of) its cache. Calling b-c-f on point-min...point-max would be perfectly fine, indeed. But currently b-c-f is not called at all. Stefan