GNU bug report logs -
#23079
25.0.92; Movement commands leave cursor in invisible line
Previous Next
Reported by: Michael Heerdegen <michael_heerdegen <at> web.de>
Date: Mon, 21 Mar 2016 20:20:01 UTC
Severity: normal
Tags: notabug
Found in version 25.0.92
Done: Stefan Kangas <stefan <at> marxist.se>
Bug is archived. No further changes may be made.
Full log
Message #34 received at 23079 <at> debbugs.gnu.org (full text, mbox):
> (let ((inhibit-read-only t)
> (deactivate-mark nil)
> (selection (magit-region-sections)))
> (mapc #'delete-overlay magit-section-highlight-overlays)
> (setq magit-section-unhighlight-sections
> magit-section-highlighted-sections
> magit-section-highlighted-sections nil)
> (unless (eq section magit-root-section)
> (run-hook-with-args-until-success
> 'magit-section-highlight-hook section selection))
> (--each magit-section-unhighlight-sections
> (run-hook-with-args-until-success
> 'magit-section-unhighlight-hook it selection))
> (restore-buffer-modified-p nil)
Hmm... what kind of buffer modifications might happen in here?
I think this might be the problem: point-adjustment is only applied after
"movement commands" and is disabled if the buffer was modified during
the course of the command (including post-command-hook).
[ This is mostly due to the simplistic way we keep track of the
"previous state", which we can't trust if the buffer was modified. ]
> This function doesn't move point, but it somehow interferes with point
> adjustment in another way.
It's difficult to adjust point without risking adverse effects in corner
cases (typically problems like "repeated C-n gets stuck" or "forward-foo
moves backward"), so point-adjustment is conservative to try and make
sure it's only done when we're sure it's "safe".
Stefan
This bug report was last modified 4 years and 294 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.