summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/help-fns.el14
1 files changed, 13 insertions, 1 deletions
diff --git a/lisp/help-fns.el b/lisp/help-fns.el
index c7667cb2dd7..40e589b3e0a 100644
--- a/lisp/help-fns.el
+++ b/lisp/help-fns.el
@@ -262,9 +262,21 @@ interactive command."
fn))
(list fn)))
+(declare-function project-combine-directories "project" (&rest lists))
+
+(cl-defmethod xref-backend-references ((_backend (eql 'elisp)) identifier
+ &context (major-mode help-mode))
+ (mapcan
+ (lambda (dir)
+ (message "Searching %s..." dir)
+ (redisplay)
+ (prog1
+ (xref-references-in-directory identifier dir)
+ (message "Searching %s... done" dir)))
+ (project-combine-directories (elisp-load-path-roots))))
+
(defun help-fns--setup-xref-backend ()
(add-hook 'xref-backend-functions #'elisp--xref-backend nil t)
- (setq-local project-vc-external-roots-function #'elisp-load-path-roots)
(setq-local semantic-symref-filepattern-alist '((help-mode "*.el"))))
;;;###autoload