GNU bug report logs - #41879
28.0.50; [Patch]: Add project-switch-to-buffer in project.el

Previous Next

Package: emacs;

Reported by: Theodor Thornhill <theo <at> thornhill.no>

Date: Mon, 15 Jun 2020 17:52:01 UTC

Severity: normal

Tags: patch

Found in version 28.0.50

Done: Dmitry Gutov <dgutov <at> yandex.ru>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 41879 <at> debbugs.gnu.org (full text, mbox):

From: Theodor Thornhill <theo <at> thornhill.no>
To: Dmitry Gutov <dgutov <at> yandex.ru>, 41879 <at> debbugs.gnu.org
Subject: Re: bug#41879: 28.0.50;
 [Patch]: Add project-switch-to-buffer in project.el
Date: Mon, 15 Jun 2020 22:05:59 +0000
[Message part 1 (text/plain, inline)]
Hey,
"Dmitry Gutov" <dgutov <at> yandex.ru> writes:


[...]
> I see that the code uses project--completing-read-strict. I'm not
> entirely happy with that function, yet.
Ok, I just thought I'd use something already written :)

>
> Have you tried calling read-buffer with a PREDICATE argument instead?
> That would require extracting some code from project--list-buffers
> (defined in Philip's patch), but it should be straightforward.

The attached patch works fine, and is also not reliant on Philip's patch. I omitted the DEF argument, since then I had to do the filtering beforehand, and also in the PREDICATE function. Just seems a little redundant to me, but maybe it should be there

The complete patch is a lot smaller now as well!
What do you think?

Theo

[pr-switch-to-buffer.patch (text/x-patch, attachment)]

This bug report was last modified 4 years and 333 days ago.

Previous Next


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