GNU bug report logs - #79200
31.0.50; Duplicated elements for '#<marker at' in buffer-undo-list

Previous Next

Package: emacs;

Reported by: Óscar Fuentes <oscarfv <at> eclipso.eu>

Date: Fri, 8 Aug 2025 16:45:03 UTC

Severity: normal

Found in version 31.0.50

Full log


Message #221 received at 79200 <at> debbugs.gnu.org (full text, mbox):

From: Gerd Möllmann <gerd.moellmann <at> gmail.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: pipcet <at> protonmail.com, Helmut Eller <eller.helmut <at> gmail.com>,
 Óscar Fuentes <oscarfv <at> eclipso.eu>,
 Alan Mackenzie <acm <at> muc.de>, 79200 <at> debbugs.gnu.org,
 Eli Zaretskii <eliz <at> gnu.org>
Subject: Re: bug#79200: 31.0.50; Duplicated elements for '#<marker at' in
 buffer-undo-list
Date: Tue, 12 Aug 2025 10:03:01 +0200
Stefan Monnier <monnier <at> iro.umontreal.ca> writes:

>> I still don't understand why these marker entries in the undo list are
>> made. Maybe someone else knows?
>
> The automatic update of markers is insufficiently precise when the we
> undo a text deletion, because all the markers that were anywhere within
> the deleted text end up with the same position after the deletion.
> So we have to record the offset for those markers that were in the
> middle of the deleted text such that when we re-insert the text we can
> put those markers back to where they were.

Ah, right, of course! Thanks!




This bug report was last modified 2 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.