From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Sean McAfee Newsgroups: gmane.emacs.bugs 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-ID: References: <865xrkgc9r.fsf@gnu.org> <86mskiws3w.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="0000000000003f62d70621bb4111" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29067"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 72862@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Sep 10 05:15:21 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1snrLc-0007PN-LY for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 10 Sep 2024 05:15:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1snrLJ-0007hx-1y; Mon, 09 Sep 2024 23:15:01 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1snrLG-0007hl-7w for bug-gnu-emacs@gnu.org; Mon, 09 Sep 2024 23:14:58 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1snrLF-0001ij-VX for bug-gnu-emacs@gnu.org; Mon, 09 Sep 2024 23:14:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=Date:From:In-Reply-To:References:MIME-Version:To:Subject; bh=G5wDkrFg1XrDTIRM3T0tvYwSfZnD4eyfYwumiWHC54M=; b=t+PMmCPjWA+M/L7pO5DmPlbTNyl69vqzdlmYDnSZBt7n4JPayOdKjcnPgvteSBAs3DbXf6gppX0DcBxUHiZfYx5eEtOyab2CJPn626R7xRKIZLNX9fY72C8Pfyq9kx/UoKv3T6nyW4YCAVVHtT5n4rpn1Us/46ygQ9JtZ1PQc1LK9sS6akdCRFU9dbtVz7klGvIPQ32MapxUMtVq3rZcBtu+yHh/Ro2kXsioJz1W3NQK0mXzmTG7xrwU2IcWaEBDEwPXe2glYvXH6wPIconNcYRwaZzxn6bpeSa7pvwhH0F09IrIta3RU1LQFvJA9JyrMNJ3TP2AlNY88olGK0cHNA==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1snrLJ-000639-UU for bug-gnu-emacs@gnu.org; Mon, 09 Sep 2024 23:15:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Sean McAfee Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 10 Sep 2024 03:15:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72862 X-GNU-PR-Package: emacs Original-Received: via spool by 72862-submit@debbugs.gnu.org id=B72862.172593807023191 (code B ref 72862); Tue, 10 Sep 2024 03:15:01 +0000 Original-Received: (at 72862) by debbugs.gnu.org; 10 Sep 2024 03:14:30 +0000 Original-Received: from localhost ([127.0.0.1]:34480 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1snrKn-00061z-Tm for submit@debbugs.gnu.org; Mon, 09 Sep 2024 23:14:30 -0400 Original-Received: from mail-yw1-f179.google.com ([209.85.128.179]:48250) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1snrKm-00061k-28 for 72862@debbugs.gnu.org; Mon, 09 Sep 2024 23:14:29 -0400 Original-Received: by mail-yw1-f179.google.com with SMTP id 00721157ae682-6da395fb97aso1638457b3.0 for <72862@debbugs.gnu.org>; Mon, 09 Sep 2024 20:14:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1725937997; x=1726542797; darn=debbugs.gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=G5wDkrFg1XrDTIRM3T0tvYwSfZnD4eyfYwumiWHC54M=; b=MHe2sq5u7x2/hEyhoarYFDrxNqY9ssSL7jPJx/3pt1DwcWLdlFFVYP2nJCy4EvIfCW Mn0v6FubjfMFUmbqhSb6M2kj2x49Kc0ONZuWwpNr0LAJVkJ+tPzVqfzak4LFsBLnqjSe h2K9Srj9bDtxyb9K07vAxXaIVL0xOS6NizEpkBr2jtnmQfa3QuHNkOVudIT17ESW3nQI vUy0N2ufb2/qQ0X6JHZoCu4WFgRQj2uoA35QK4mafzkw8vch+0i0nug3zdS4kGjYjhe3 RqzEJIgAoU9vja/7pEXsBpjYReyVvTwyTfCa8anp5vGj7W4XbxpISYkVHFIFj6dnRtCK s+rw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725937997; x=1726542797; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=G5wDkrFg1XrDTIRM3T0tvYwSfZnD4eyfYwumiWHC54M=; b=mcU8qyvwkGOeiA2a4TU82WwOXoX0Kmte5bS7LSo9V0UpLKmusiQUbjD9O7qOVQB8cA kkm5E3e6BHkgkEcM5XMPPRluXSKb41RXRvNZ0w+fjPCyzHfDXY4UcA+CszYAtUcfR7ey Wx9Mfa9iicgrvEqLFBpGtKBSSRDTkH1UtYFWJ/kNjcPT8iQnJ+pWUdnHhv5aqDND6VGh qQcK8dJFSLwY/sPDmGq6ZjNzhvOKpp/bLtbYjpF1e1aEVOIIFMU57xPys+wZxi46mFye gDoam2YVSM3x6iTJrTjG+tB6PXWgfCcx9adPRwU9yHA9gIqrROAD7hjDy4KUKvmZMIIc Xunw== X-Gm-Message-State: AOJu0Yx0n97NKBy1YHUhLE0sRfvyOiZxIGvLKDY9jnmlRJ5IheKo5oqz 6MPUuPQY859oSaxhOnEZnddNKF37KCP4hjR+YYTKyTI4MhunOupTmjmhSUVaV508oruY9xSSJqq YDwAN9V+ozUhMYpZ0Inx8GAUBbzc= X-Google-Smtp-Source: AGHT+IF82RJnPQMxJRlPrr1rFakQ66XAGOmWTXgna8gQ7+d6zSSPy2wjrAdmunnW2HOdrCXnvRJHPelBev8SyuDTn6I= X-Received: by 2002:a05:690c:2d09:b0:6b9:fd00:95c9 with SMTP id 00721157ae682-6db45154c3fmr102970937b3.28.1725937997535; Mon, 09 Sep 2024 20:13:17 -0700 (PDT) In-Reply-To: <86mskiws3w.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:291535 Archived-At: --0000000000003f62d70621bb4111 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Sun, Sep 8, 2024 at 1:56=E2=80=AFAM Eli Zaretskii 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. --0000000000003f62d70621bb4111 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Sun, Sep 8, 2024 at 1:56=E2=80=AFAM El= i Zaretskii <eliz@gnu.= org> wrote:
Since kill-whole-line kills both backward and for= ward from point, it
seems we should expect that the first part is prepended to previous
kill, whereas the second part is appended.=C2=A0 Which is what the command<= br> already does.

WDYT?

Since the current behavior is exp= licitly documented in the code, I suppose that settles it.=C2=A0 I really c= an't imagine a good use case for it, though.=C2=A0 But then again, unti= l I filed this ticket, I didn't know that append-next-kill could someti= mes prepend instead of append.=C2=A0 It seems a small miracle that I've= never stumbled across the prepending function by accident.

<= /div>
Perhaps kill-whole-line does technically kill both forwards and b= ackwards, but to me it's always been just a welcome shortcut for the cl= assic Emacs idiom C-a C-k C-k.=C2=A0 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.=C2=A0 If the current behavior is to stay, the= n I think it could stand to be called out explicitly in the documentation f= or kill-whole-line.

Anyway!=C2=A0 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.

--0000000000003f62d70621bb4111--