help-gnu-emacs
[Top][All Lists]
Advanced

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

RE: Reverting but keeping undo


From: Drew Adams
Subject: RE: Reverting but keeping undo
Date: Tue, 28 May 2013 20:09:24 -0700 (PDT)

> > `revert-buffer' discards undo history.
> 
> FWIW, I just installed a patch in Emacs's trunk which makes that
> revert-buffer doesn't discard undo history any more.

Hm.  So `revert-buffer' no longer removes undo?  That has always been a part of 
what reverting means.  And it is clearly intended in the code, not just an 
unfortunate accident or oversight.

If some code or user has a use for not removing undo, fine.  But why not make 
this removal optional, controlled, e.g., by a variable or a parameter?  Why 
willy nilly remove something clearly intended from the beginning to be an 
integral part of reverting (at least by default)?

And why no discussion beforehand?  I can't think of a great reason why undo 
should *always* be removed as part of reverting (as it always has been).  But 
just maybe there is a good reason for doing that, at least some or even most of 
the time.  Why not give Richard et al the benefit of the doubt (30 years of 
"classic" reverting) and make undo removal optional, at least for a while?  (Or 
is doubt a no-no?)

Let's not forget either that `revert-buffer' is used both in code and 
interactively.  Those two uses are sometimes quite different.



reply via email to

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