From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lars Magne Ingebrigtsen Newsgroups: gmane.emacs.bugs Subject: bug#2553: *vc-diff* buffers are read-only, but M-k works Date: Thu, 06 Oct 2011 23:59:02 +0200 Message-ID: References: <87k575jnwl.fsf@cyd.mit.edu> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1317938527 11375 80.91.229.12 (6 Oct 2011 22:02:07 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 6 Oct 2011 22:02:07 +0000 (UTC) Cc: 2553@debbugs.gnu.org, emacs-devel@gnu.org, David Reitter To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Oct 07 00:02:00 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RBw0t-0007e2-9d for geb-bug-gnu-emacs@m.gmane.org; Fri, 07 Oct 2011 00:01:59 +0200 Original-Received: from localhost ([::1]:49301 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RBw0s-0007Ze-Rw for geb-bug-gnu-emacs@m.gmane.org; Thu, 06 Oct 2011 18:01:58 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:45496) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RBw0o-0007Z7-KM for bug-gnu-emacs@gnu.org; Thu, 06 Oct 2011 18:01:56 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RBw0n-0000gv-EG for bug-gnu-emacs@gnu.org; Thu, 06 Oct 2011 18:01:54 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:43043) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RBw0n-0000gr-9c for bug-gnu-emacs@gnu.org; Thu, 06 Oct 2011 18:01:53 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RBw0v-0002ZA-Po for bug-gnu-emacs@gnu.org; Thu, 06 Oct 2011 18:02:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Lars Magne Ingebrigtsen Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 06 Oct 2011 22:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 2553 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 2553-submit@debbugs.gnu.org id=B2553.13179384819816 (code B ref 2553); Thu, 06 Oct 2011 22:02:01 +0000 Original-Received: (at 2553) by debbugs.gnu.org; 6 Oct 2011 22:01:21 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RBw0G-0002YG-3p for submit@debbugs.gnu.org; Thu, 06 Oct 2011 18:01:21 -0400 Original-Received: from hermes.netfonds.no ([80.91.224.195]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RBw0C-0002Y7-Oq for 2553@debbugs.gnu.org; Thu, 06 Oct 2011 18:01:18 -0400 Original-Received: from cm-84.215.51.58.getinternet.no ([84.215.51.58] helo=stories.gnus.org) by hermes.netfonds.no with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1RBvzu-0002ix-MP; Fri, 07 Oct 2011 00:00:58 +0200 In-Reply-To: (Stefan Monnier's message of "Mon, 12 Sep 2011 21:26:03 -0400") User-Agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.90 (gnu/linux) X-Now-Playing: Clogs's _The Creatures in the Garden of Lady Walton_: "On the Edge" X-MailScanner-ID: 1RBvzu-0002ix-MP MailScanner-NULL-Check: 1318543258.87945@iZUGlOC9J5vJj7fkVO2Xlg X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Thu, 06 Oct 2011 18:02:01 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:52323 Archived-At: Stefan Monnier writes: >> Perhaps a more general solution would be possible here. I think there >> probably are other "mostly-read-only" modes where you have one or two >> special commands that alter the buffer, anyway. Like with `M-k'. >> Perhaps there could be a buffer-local variable like >> `undo-read-only-buffer' that if set, would allow `undo' to work in these >> cases. > > Or we could record in the buffer-undo-list the fact the the modification > was done with inhibit-read-only bound to non-nil, and bind it similarly > during the undo. That would be even better, and is even more general. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog http://lars.ingebrigtsen.no/