GNU bug report logs - #38294
[PATCH] Handle killing of virtual buffers in Ido

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Dario Gjorgjevski <dario.gjorgjevski@HIDDEN>; Keywords: patch; dated Wed, 20 Nov 2019 08:58:02 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 20 Nov 2019 08:57:06 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Nov 20 03:57:06 2019
Received: from localhost ([127.0.0.1]:48964 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1iXLnL-0004aS-0h
	for submit <at> debbugs.gnu.org; Wed, 20 Nov 2019 03:57:06 -0500
Received: from lists.gnu.org ([209.51.188.17]:37626)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <dario.gjorgjevski@HIDDEN>) id 1iXLnJ-0004a3-Lp
 for submit <at> debbugs.gnu.org; Wed, 20 Nov 2019 03:57:02 -0500
Received: from eggs.gnu.org ([2001:470:142:3::10]:37814)
 by lists.gnu.org with esmtp (Exim 4.90_1)
 (envelope-from <dario.gjorgjevski@HIDDEN>) id 1iXLnI-0002a3-CP
 for bug-gnu-emacs@HIDDEN; Wed, 20 Nov 2019 03:57:01 -0500
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM,
 URIBL_BLOCKED autolearn=disabled version=3.3.2
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <dario.gjorgjevski@HIDDEN>) id 1iXLnF-0003Et-TO
 for bug-gnu-emacs@HIDDEN; Wed, 20 Nov 2019 03:57:00 -0500
Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]:50520)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16)
 (Exim 4.71) (envelope-from <dario.gjorgjevski@HIDDEN>)
 id 1iXLnD-00037y-LK
 for bug-gnu-emacs@HIDDEN; Wed, 20 Nov 2019 03:56:56 -0500
Received: by mail-wm1-x32b.google.com with SMTP id l17so6107665wmh.0
 for <bug-gnu-emacs@HIDDEN>; Wed, 20 Nov 2019 00:56:52 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:subject:date:message-id:mime-version;
 bh=c7hG6Ch/G92qcCTc6TNkznR3sjDS0WaJOPFJq41eOvA=;
 b=tDwLyy3H5Rxvg39GuP04aKsPZrA3MuwR1LdDr5oxd31SU+nEbZlKGFGr1G7z13KGmp
 7URxaTEm6BRwH/0eJ56VZusm5oaZ07vkgkNc1GJROomnfPgphC/eE0Ne4WblnfqQcHMh
 vaCRAFoAYfGd5tuMk4/s830jlIFVCbyiW6pislvyX+URBYNgfEjCY8h4nBAKDRKupU88
 atJbe0ESvCy/hRDjbxXkseB4aupM/4jV95AWr8xSzsxmbAZL37xbe2DjT5Mm/6nSkykx
 p+CZd8F0UZS811/yhZ7MjCiKmTCptfbZgXpSb/4fvqpu2R66gOlOQm5iUn+VBxLHaR6d
 hD5w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:subject:date:message-id:mime-version;
 bh=c7hG6Ch/G92qcCTc6TNkznR3sjDS0WaJOPFJq41eOvA=;
 b=BdEQT+yvog81GXQ42DRpJN194jxDDmcx2CYO16kD9lbdq9KGIxhHsNd5NEHTpK+nyR
 a6qHE7EOJa43LoxiJBhQKxlDnf48QU5mNzziD4k3UbyT+8vX1g/jgdB1Z/8esnHKdSPw
 Fu1FosLmMSh/wSc6XIl+hCsQVfe9zmfPJ9uR63HorB6WP0e/Bss51PM9i9jHCtd1oxl6
 ZI1yh+AD2JyzZjvidROxm0TY0UCmjmyh52+2S25pSBYbOw1/yCjJyAI4cYtZ+FPANI2L
 o1fdZMDJEodXSeeQc8rk/RieawRKHzZeOqf7okLk9MhaTHB3PE4FgSWLferaWPuwo1Gp
 gyAA==
X-Gm-Message-State: APjAAAVltCJU99PBD9567DsgBsnJ6cRClD6OBhKfwvyc4FTiLhTHDsZp
 P2WEi2cIr3IwJRGeyMalyJMDLU4y
X-Google-Smtp-Source: APXvYqyO4CAATQFYVa8l/jmpqikD4pEkoaLMy8O7tZboiSwXxY6Wf92BDPx7lCeGYz9C7zmfe3Q3Sw==
X-Received: by 2002:a05:600c:2253:: with SMTP id
 a19mr1799018wmm.97.1574240211447; 
 Wed, 20 Nov 2019 00:56:51 -0800 (PST)
Received: from ZALANDO-31298 ([185.85.220.254])
 by smtp.gmail.com with ESMTPSA id d7sm30885720wrx.11.2019.11.20.00.56.50
 for <bug-gnu-emacs@HIDDEN>
 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256);
 Wed, 20 Nov 2019 00:56:50 -0800 (PST)
From: Dario Gjorgjevski <dario.gjorgjevski@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: [PATCH] Handle killing of virtual buffers in Ido
Date: Wed, 20 Nov 2019 09:56:43 +0100
Message-ID: <fv2zoj36ejncxg.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="=-=-="
X-detected-operating-system: by eggs.gnu.org: Genre and OS details not
 recognized.
X-Received-From: 2a00:1450:4864:20::32b
X-Spam-Score: 0.7 (/)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

--=-=-=
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

Currently, =E2=80=98ido-kill-buffer=E2=80=99 does essentially nothing to vi=
rtual
buffers.  (They are visited and then immediately killed.)  The attached
patch changes that so that they are instead removed from =E2=80=98recentf-l=
ist=E2=80=99,
akin to =E2=80=98ido-kill-buffer-at-head=E2=80=99.


--=-=-=
Content-Type: text/x-diff
Content-Disposition: inline;
 filename=0001-Handle-killing-of-virtual-buffers-in-Ido.patch
Content-Description: Handle killing of virtual buffers in Ido

From 4295cac14ea280d43c0aa493520543aa403a4c2e Mon Sep 17 00:00:00 2001
From: Dario Gjorgjevski <dario.gjorgjevski+git@HIDDEN>
Date: Wed, 20 Nov 2019 09:34:58 +0100
Subject: [PATCH] Handle killing of virtual buffers in Ido
To: bug-gnu-emacs@HIDDEN

* lisp/ido.el (ido-buffer-internal): Handle killing of virtual buffers
as a special case.
(ido-visit-buffer): Document the special case.
---
 lisp/ido.el | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/lisp/ido.el b/lisp/ido.el
index 79f259b819..bf3f57883d 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -2286,7 +2286,10 @@ ido-buffer-internal
        ((and ido-enable-virtual-buffers
 	     ido-virtual-buffers
 	     (setq filename (assoc buf ido-virtual-buffers)))
-	(ido-visit-buffer (find-file-noselect (cdr filename)) method t))
+        (if (eq method 'kill)
+            (setq recentf-list
+	          (delete (cdr filename) recentf-list))
+	  (ido-visit-buffer (find-file-noselect (cdr filename)) method t)))
 
        ((and (eq ido-create-new-buffer 'prompt)
 	     (null require-match)
@@ -4128,6 +4131,8 @@ ido-visit-buffer
       (setq buffer (buffer-name buffer)))
   (let (win newframe)
     (cond
+     ;; "killing" of virtual buffers is handled in
+     ;; `ido-buffer-internal'
      ((eq method 'kill)
       (if record
 	  (ido-record-command 'kill-buffer buffer))
-- 
2.17.1


--=-=-=--




Acknowledgement sent to Dario Gjorgjevski <dario.gjorgjevski@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#38294; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 25 Nov 2019 12:00:02 UTC

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