When teleporting some text, then the minibuffer shows the message Mark set. But the messages buffer shows that the killed text was printed as Killed: <killed text> before Mark set. The first message is never seen without opening the messages buffer.
Steps to reproduce
Start Emacs
Type:
one
two
three
Move the cursor the the o in one.
Call M-x avy-goto-line
Press t to start a teleport action
Press s to target the second line two
Observed
The minibuffer shows Mark set, but the messages buffer shows:
Killed: two
Mark set
Expected
The minibuffer should probably show the Killed: two message.
I'm not sure if it's important to see the Mark set message.
If not, then maybe the yank command could be replaced with:
(insert (car kill-ring))
Or maybe the killed message could be shown after the yank command, then the Mark set message will still be visible in the messages buffer. But I'm not sure how this could be done, since the message and yank command are called in different functions.
When teleporting some text, then the minibuffer shows the message
Mark set
. But the messages buffer shows that the killed text was printed asKilled: <killed text>
beforeMark set
. The first message is never seen without opening the messages buffer.Steps to reproduce
o
inone
.M-x avy-goto-line
t
to start a teleport actions
to target the second linetwo
Observed
The minibuffer shows
Mark set
, but the messages buffer shows:Expected
The minibuffer should probably show the
Killed: two
message.Possible cause
The
avy-action-kill-stay
function calls:(message "Killed: %s" (current-kill 0))
https://github.com/abo-abo/avy/blob/6459f7f12aef1e71ff5e265b1edb414fd81123e6/avy.el#L683But when the
avy-action-kill-stay
function is done, thenavy-action-teleport
ends up calling(yank)
https://github.com/abo-abo/avy/blob/6459f7f12aef1e71ff5e265b1edb414fd81123e6/avy.el#L696 which printsMark set
to the minibuffer. That replaces theKilled: two
text before one is able to see it.Possible solution:
I'm not sure if it's important to see the
Mark set
message. If not, then maybe the yank command could be replaced with:Or maybe the killed message could be shown after the yank command, then the Mark set message will still be visible in the messages buffer. But I'm not sure how this could be done, since the message and yank command are called in different functions.