From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eshel Yaron Newsgroups: gmane.emacs.devel Subject: Re: master 048e72a403e 1/2: Add file/buffer-to-register (Bug#73308) Date: Tue, 08 Oct 2024 11:36:23 +0200 Message-ID: References: <172812286261.457694.4614807424585269986@vcs3.savannah.gnu.org> <20241005100743.4B6DB1AA78D@vcs3.savannah.gnu.org> <87r08s24xz.fsf@ocathain.ie> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="31549"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: emacs-devel@gnu.org To: Barra =?utf-8?B?w5MgQ2F0aMOhaW4=?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Oct 08 11:37:21 2024 Return-path: Envelope-to: ged-emacs-devel@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 1sy6ee-00082u-7o for ged-emacs-devel@m.gmane-mx.org; Tue, 08 Oct 2024 11:37:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sy6du-0001oX-Dy; Tue, 08 Oct 2024 05:36:34 -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 1sy6dr-0001oJ-PL for emacs-devel@gnu.org; Tue, 08 Oct 2024 05:36:31 -0400 Original-Received: from mail.eshelyaron.com ([107.175.124.16] helo=eshelyaron.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sy6dq-00004w-D9 for emacs-devel@gnu.org; Tue, 08 Oct 2024 05:36:31 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=eshelyaron.com; s=mail; t=1728380185; bh=W1yE5EWrdev6bTx+TejOyW1JRi7MhSQoELeP3m9udQc=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=m8RzDEWiYp5g1T1jRPlz3G5ND2yG3RVmEHaT0pkuTuziFrScOAX43hXocdf6yBWr6 uD8sbC2ZugSdcYu8VUJW/hu8qecBxxRZLzvMAMcaiUzBZWd3ifyOnGPDbdnd4IOVqI 3SSsdn7AsjssSqIsmK8radh36IBpZqnUweR/Ii8v6GWuRKhtn+HmhQJt48TtdswMxX 0nl9riUD77NOOZgaYPiSyDHmUN/JXv4p3oT3B+N9+QF7BBT+ZsVaSnf23FSQ6hdtaB Iph94CqLie88NqQhv5HSPasHMoHJ/hcplpwN77S9AJj26y9eSTwipRwEvNdXk5fdF4 S+WENLPgGVhqg== In-Reply-To: <87r08s24xz.fsf@ocathain.ie> ("Barra =?utf-8?B?w5MgQ2F0aMOh?= =?utf-8?B?aW4iJ3M=?= message of "Mon, 07 Oct 2024 00:21:28 +0100") X-Hashcash: 1:20:241008:emacs-devel@gnu.org::9VVD1sRSA1zhGLU5:0Qr7 X-Hashcash: 1:20:241008:barra@ocathain.ie::VCorC3qmSr9XHz02:1RF/ Received-SPF: pass client-ip=107.175.124.16; envelope-from=me@eshelyaron.com; helo=eshelyaron.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:324411 Archived-At: Hi, Barra =C3=93 Cath=C3=A1in writes: > D'oh! You're absolutely correct. I've attached a patch containing a fix > for exactly this; adds a check to see if buffer is currently alive, > and uses with-current-buffer to ensure that it's adding to the correct > one. Thanks! I've applied your patch (with a minor tweak to the commit message) in commit c0f10fc3d48. I then followed up with a couple of small refinements in commit 6a272dedad3It. I mostly improved the docstring and the minibuffer prompts, but note that I removed the (let ((buffer (or (get-buffer buffer) buffer))) ...) binding: it only has any effect if BUFFER is a string, which it isn't, it's a buffer. Let me know if I misread something. > Let me know if I should send this somewhere else; I'm still > learning mailing list development etiquette. This is fine for such a follow up, I think. Best, Eshel