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: insert-file-contents and format-decode Date: Tue, 26 Jun 2007 18:48:28 -0400 Message-ID: References: <4666BF5F.5030301@gmx.at> <46753850.2090708@gmx.at> <46778ACB.1000704@gmx.at> <467E47AF.1080702@gmx.at> <4680B80E.5090709@gmx.at> Reply-To: rms@gnu.org NNTP-Posting-Host: lo.gmane.org Content-Type: text/plain; charset=ISO-8859-15 X-Trace: sea.gmane.org 1182898185 1537 80.91.229.12 (26 Jun 2007 22:49:45 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 26 Jun 2007 22:49:45 +0000 (UTC) Cc: emacs-devel@gnu.org To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jun 27 00:49:44 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 1I3Jqw-00045f-W1 for ged-emacs-devel@m.gmane.org; Wed, 27 Jun 2007 00:49:43 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I3Jqw-00074h-F0 for ged-emacs-devel@m.gmane.org; Tue, 26 Jun 2007 18:49:42 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I3Jpl-0006c9-OC for emacs-devel@gnu.org; Tue, 26 Jun 2007 18:48:29 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I3Jpk-0006bd-Oi for emacs-devel@gnu.org; Tue, 26 Jun 2007 18:48:29 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I3Jpk-0006bU-Io for emacs-devel@gnu.org; Tue, 26 Jun 2007 18:48:28 -0400 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1I3Jpk-0004hL-7T for emacs-devel@gnu.org; Tue, 26 Jun 2007 18:48:28 -0400 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.60) (envelope-from ) id 1I3Jpk-0002Ym-0J; Tue, 26 Jun 2007 18:48:28 -0400 In-reply-to: <4680B80E.5090709@gmx.at> (message from martin rudalics on Tue, 26 Jun 2007 08:54:06 +0200) 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:73891 Archived-At: > Is your suggestion to fix this by disabling the modification hooks in > Finsert_file_contents around the call to `format-decode'? Either in Finsert_file_contents or within `format-decode'. I think it is ok to disable them unconditionally inside `format-decode'. Decoding is sufficiently low level that it probably makes no sense to expect them to run these hooks. Then Finsert_file_contents can run the hooks just once for the (decoded) text that is ultimately inserted. I'm not sure what to do with `after-insert-file-functions' though. The current documentation suggests that these are handled the same way as the `format-decode' based functions. If you want to keep the current behavior for them, this should be documented throughly. That means, the documentation should say that functions in `after-insert-file-functions' have to take care of narrowing, `buffer-undo-list', after-change hooks, and the like. With the current plan, they don't have to deal with undo or change hooks. How do they have "take care of" narrowing?