From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: [n_schumacher@web.de: modification hooks called only once in c-mode] Date: Sun, 12 Aug 2007 00:14:43 -0400 Message-ID: References: <874pj6j3te.fsf@stupidchicken.com> Reply-To: rms@gnu.org NNTP-Posting-Host: lo.gmane.org Content-Type: text/plain; charset=ISO-8859-15 X-Trace: sea.gmane.org 1186891895 17433 80.91.229.12 (12 Aug 2007 04:11:35 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 12 Aug 2007 04:11:35 +0000 (UTC) Cc: emacs-devel@gnu.org To: Chong Yidong Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Aug 12 06:11:33 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 1IK4na-00085D-RA for ged-emacs-devel@m.gmane.org; Sun, 12 Aug 2007 06:11:31 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IK4na-00075c-5D for ged-emacs-devel@m.gmane.org; Sun, 12 Aug 2007 00:11:30 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1IK4nX-00074H-9A for emacs-devel@gnu.org; Sun, 12 Aug 2007 00:11:27 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1IK4nW-00073s-U4 for emacs-devel@gnu.org; Sun, 12 Aug 2007 00:11:27 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IK4nW-00073k-PW for emacs-devel@gnu.org; Sun, 12 Aug 2007 00:11:26 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1IK4nW-00037Y-IZ for emacs-devel@gnu.org; Sun, 12 Aug 2007 00:11:26 -0400 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.60) (envelope-from ) id 1IK4qh-0006Qx-1J; Sun, 12 Aug 2007 00:14:43 -0400 In-reply-to: <874pj6j3te.fsf@stupidchicken.com> (message from Chong Yidong on Fri, 10 Aug 2007 20:46:37 -0400) X-Detected-Kernel: Linux 2.6, seldom 2.4 (older, 4) 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:76368 Archived-At: One simple fix is to bind inhibit-modification-hooks in c-after-change. A deeper fix would be to make report_overlay_modification check if it is being called in a modification hook, and take steps to prevent scheduled hooks from being rubbed out. I'm not sure this behavior is significantly more "correct" than the existing one, however; it may be better to leave it as is. It seems to me that the cleanest kind of fix is to save the relevant data around actually invoking the hooks. How hard or ugly is that?