aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2024-10-03 10:25:13 -0400
committerStefan Monnier2024-10-03 10:25:13 -0400
commit8683d64cc571500347a16e7cb7d144d723250489 (patch)
tree88092530b032876529450f2643e0d0151de602f6
parentb9ebacf40345977ddf18531cb1ebf0f6c56045ae (diff)
downloademacs-8683d64cc571500347a16e7cb7d144d723250489.tar.gz
emacs-8683d64cc571500347a16e7cb7d144d723250489.zip
(help--symbol-completion-table): Try and fix bug#73473
* lisp/help-fns.el (help--symbol-completion-table): Be more careful with `help-enable-completion-autoload` so we don't load a package in cases where we already know it won't impact the result.
-rw-r--r--lisp/help-fns.el7
1 files changed, 5 insertions, 2 deletions
diff --git a/lisp/help-fns.el b/lisp/help-fns.el
index 40e589b3e0a..5cc8df6497f 100644
--- a/lisp/help-fns.el
+++ b/lisp/help-fns.el
@@ -206,9 +206,12 @@ type specifier when available."
206 ,@(when completions-detailed 206 ,@(when completions-detailed
207 '((affixation-function . help--symbol-completion-table-affixation))) 207 '((affixation-function . help--symbol-completion-table-affixation)))
208 (category . symbol-help)) 208 (category . symbol-help))
209 (when help-enable-completion-autoload 209 (when (and help-enable-completion-autoload
210 (memq action '(nil t lambda)))
210 (let ((prefixes (radix-tree-prefixes (help-definition-prefixes) string))) 211 (let ((prefixes (radix-tree-prefixes (help-definition-prefixes) string)))
211 (help--load-prefixes prefixes))) 212 ;; Don't load FOO.el during `test-completion' of `FOO-'.
213 (unless (and (eq action 'lambda) (assoc string prefixes))
214 (help--load-prefixes prefixes))))
212 (let ((prefix-completions 215 (let ((prefix-completions
213 (and help-enable-completion-autoload 216 (and help-enable-completion-autoload
214 (mapcar #'intern (all-completions string definition-prefixes))))) 217 (mapcar #'intern (all-completions string definition-prefixes)))))