Eli Zaretskii writes: >> From: phillip.lord@russet.org.uk (Phillip Lord) >> Cc: Eli Zaretskii , 23871@debbugs.gnu.org >> Date: Fri, 01 Jul 2016 23:21:01 +0100 >> >> (let ((p (start-process "bc" (current-buffer) "bc"))) >> (process-send-string p "2^10\n") >> (goto-char (point-max))) >> >> The strange thing here is that it's not specifically an undo problem. >> Point doesn't move after eval-defun. > > The problem, AFAIU, is in point movements _during_ eval-defun: they > seem to not be recorded in buffer-undo-list. The undo list I get > after C-M-x is this: > > (nil (117 . 122) (t 22391 27551 0 0)) > So, I don't think this is a regression caused by my patch at all. It is an bug that has been there since I altered undo.c last year. The problem was caused because of undo only records point after a boundary (or the first element). I'd changed things during slightly when I update undo.c so that the timestamp list got added before checking whether I was at a boundary, hence blocking addition of the point restoration information. This is why I found the problem so erratic to replicate; it only occurs immediately the first change to a buffer. I believe the following patch addresses the issue. Phil