Subject: bug#79200: 31.0.50; Duplicated elements for '#<marker at' in buffer-undo-list

From: Stefan Monnier <[email-masked]>
Date: Tue, 12 Aug 2025 03:56:28 -0400

> 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.

        Stefan