emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CC mode 5.31.4: c-{beginning, end}-of-defun try to modify buffer


From: Lennart Borgman (gmail)
Subject: Re: CC mode 5.31.4: c-{beginning, end}-of-defun try to modify buffer
Date: Tue, 08 Jan 2008 21:14:25 +0100
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666

Alan Mackenzie wrote:
Hi, Andreas!

On Tue, Jan 08, 2008 at 06:13:40PM +0100, Andreas Schwab wrote:
c-{beginning,end}-of-defun try to modify the buffer and thus trigger
ask-user-about-supersession-threat.  To reproduce load a C file and
touch the underlying file.  Then type C-M-e repeatedly.  After some
tries you will be asked whether you want to edit the buffer.

Ouch!

Yes, I can reproduce this.  At a guess, it's happening because of CC
Mode's extensive use of text properties.  I don't (yet) see why it only
happens after a several C-M-e's rather than the first.  Applying text
properties counts as modifying the buffer (I think this is a Bad Thing),
and the primitive function which applies the text properties seems to be
checking for the file having been modified.  Or something like that.

Are you talking about the text properties that font lock applies? I believe those does not mark the buffer as modified.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]