Subject: bug#72787: 31.0.50; Invalid describe-function completion candidates

From: Arash Esbati <[email-masked]>
Date: Sat, 12 Oct 2024 11:41:31 +0200

Stefan Monnier <[email-masked]> writes:

> Could you clarify which part of the picture make you think so?
> [ Also, does (featurep 'dash) return nil or t before you perform that
>   completion?  ]

I do:

• emacs -Q
• Eval:
    (progn
      (setq completions-format 'vertical)
      (package-initialize)
      (featurep 'dash))
  which returns nil
• 'C-h v TAB' and see this:

Take for example "-keep".  I do 'C-h v -keep RET' and get:

  -keep is void as a variable.

  Not documented as a variable.

Now I eval (require 'dash), do 'C-h v -keep RET' again and get:

  -keep is void as a variable.

  Not documented as a variable.

whereas 'C-h f -keep' returns:

  -keep is a native-comp-function in ‘dash.el’.

  (-keep FN LIST)

  Return a new list of the non-nil results of applying FN to each item in LIST.
  Like ‘-filter’, but returns the non-nil results of FN instead of
  the corresponding elements of LIST.

  Its anaphoric counterpart is ‘--keep’.

In summary, I see a void variable in the list of completions where the
function is defined.  Also, when I do 'emacs -Q' followed directly with
'C-h f TAB', I see this:

The (setf ...) part doesn't look right to me.

> [ Also did you get this with an Emacs which includes:
>
>     commit 8683d64cc571500347a16e7cb7d144d723250489
>     Author: Stefan Monnier <[email-masked]>
>     Date:   Thu Oct 3 10:25:13 2024 -0400
> ]

$ git show 8683d64cc571500347a16e7cb7d144d723250489
commit 8683d64cc571500347a16e7cb7d144d723250489
Author: Stefan Monnier <[email-masked]>
Date:   Thu Oct 3 10:25:13 2024 -0400

    (help--symbol-completion-table): Try and fix bug#73473

I'm runnig Emacs from master (ff4de9ef) on macOS.

> Sorry for not mentioning it earlier, I stupidly assumed you were aware
> of that variable.

I'm sorry I didn't investigate enough to find out about that variable
myself.

Best, Arash