[Top][All Lists]

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

Re: [RFC]: replace-region-contents

From: Eli Zaretskii
Subject: Re: [RFC]: replace-region-contents
Date: Tue, 05 Feb 2019 18:36:14 +0200

> From: Tassilo Horn <address@hidden>
> Date: Tue, 05 Feb 2019 14:21:46 +0100
> Cc: address@hidden
> I just became aware of the fact that we cannot use
> `replace-buffer-contents' in its current state if the replacement is too
> large.  It becomes unbearable slow.

In what version of Emacs?  I think it was slow in 26.1, but wa ssped
up significantly since then.

If you are using emacs-26 or the master branch from Git, and it is
still slow, can you show an example where it's slow, and tell how much
time it took?

> I wonder where and how to fix that.  Maybe `replace-buffer-contents'
> could fall back to recognize itself if it doesn't make sense to try to
> restore point and marks, e.g., trivial cases like point is on
> (point-min) or (point-max) and there are no marks, or the replacement
> buffer's content exceeds some maximum...

AFAIR, the speed of replace-buffer-contents doesn't depend at all on
whether markers are preserved or not, so I don't think this will

reply via email to

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