GNU bug report logs - #72862
29.1; Strange interaction between append-next-kill and kill-whole-line

Previous Next

Package: emacs;

Reported by: Sean McAfee <eefacm <at> gmail.com>

Date: Wed, 28 Aug 2024 21:14:02 UTC

Severity: normal

Found in version 29.1

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Sean McAfee <eefacm <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 72862 <at> debbugs.gnu.org
Subject: bug#72862: 29.1; Strange interaction between append-next-kill and kill-whole-line
Date: Mon, 9 Sep 2024 22:13:06 -0500
[Message part 1 (text/plain, inline)]
On Sun, Sep 8, 2024 at 1:56 AM Eli Zaretskii <eliz <at> gnu.org> wrote:

> Since kill-whole-line kills both backward and forward from point, it
> seems we should expect that the first part is prepended to previous
> kill, whereas the second part is appended.  Which is what the command
> already does.
>
> WDYT?
>

Since the current behavior is explicitly documented in the code, I suppose
that settles it.  I really can't imagine a good use case for it, though.
But then again, until I filed this ticket, I didn't know that
append-next-kill could sometimes prepend instead of append.  It seems a
small miracle that I've never stumbled across the prepending function by
accident.

Perhaps kill-whole-line does technically kill both forwards and backwards,
but to me it's always been just a welcome shortcut for the classic Emacs
idiom C-a C-k C-k.  And the name kill-whole-line certainly implies to me
that the line is killed as a single unit, not killed in two steps in
opposite directions.  If the current behavior is to stay, then I think it
could stand to be called out explicitly in the documentation for
kill-whole-line.

Anyway!  Although I'd prefer to see what I'd consider to be the more
sensible behavior built into Emacs, I can achieve it on my own by just
rebinding C-S-backspace to a command that moves to the beginning of the
line before calling kill-whole-line.
[Message part 2 (text/html, inline)]

This bug report was last modified 247 days ago.

Previous Next


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