GNU bug report logs - #4718
23.1; C-h f gives doc for the wrong function

Previous Next

Package: emacs;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Wed, 14 Oct 2009 00:00:06 UTC

Severity: normal

Tags: wontfix

Done: Lars Magne Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Juanma Barranquero <lekktu <at> gmail.com>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 4718 <at> debbugs.gnu.org
Subject: bug#4718: 23.1; C-h f gives doc for the wrong function
Date: Wed, 14 Oct 2009 06:51:26 +0200
On Wed, Oct 14, 2009 at 06:24, Drew Adams <drew.adams <at> oracle.com> wrote:

> No, I'm not saying that. I have no problem with the behavior of Emacs 22 and
> before.

Aha. Sorry for misrepresenting your point.

> Letting RET complete using prefix completion is not problematic in the way that
> letting it do so with partial completion is. With only prefix completion, `dolis
> RET' can only complete to something that has `dolis' as a prefix. When there is
> only one such completion, it is not very hard to guess what that is.

But there's not necessarily just one completion. If you have cl loaded,

  C-h f defu <RET>  => defun

but it could also be `defun*'.

> That is, with prefix completion the gap between what is known (the input) and
> what is unknown (the completion) is small and predictable. If you choose to hit
> RET, it's because you pretty much know what you're going to get.

I don't think so, because <RET> is also a form of completion:

  C-h f buffer-face <RET> => "buffer-face-"
  <RET> => "Possible completions are:"

> That
> means both (a) it is unlikely that the sole completion would be much longer and
> therefore hard to guess and (b) it is not unreasonable for both the program and
> the user to consider the input as pretty much the whole function name.

It is not unreasonable, of course. But neither it is unreasonable the
opposite: to understand RET as, "if there's only one completion, give
me that". I think it's useful.

> IOW, RET, with the meaning "this is what I want" fits well here. RET in that
> sense does not fit well with partial completion, where your input could complete
> to pretty much anything.

It's a matter of tastes, I think.

> That's one solution I see: not ask for confirmation except when the completion
> does not have the input as a prefix.

That seems reasonable, though surely there's people who will feel as
strongly about it as you feel about the current default behavior :-)

    Juanma



This bug report was last modified 13 years and 313 days ago.

Previous Next


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