aboutsummaryrefslogtreecommitdiffstats
path: root/lisp
diff options
context:
space:
mode:
Diffstat (limited to 'lisp')
-rw-r--r--lisp/progmodes/elisp-mode.el8
1 files changed, 7 insertions, 1 deletions
diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el
index 8afae150a1d..7614bacf1bb 100644
--- a/lisp/progmodes/elisp-mode.el
+++ b/lisp/progmodes/elisp-mode.el
@@ -720,10 +720,15 @@ non-nil result supercedes the xrefs produced by
720 (dolist (method (cl--generic-method-table generic)) 720 (dolist (method (cl--generic-method-table generic))
721 (let* ((info (cl--generic-method-info method));; qual-string combined-args doconly 721 (let* ((info (cl--generic-method-info method));; qual-string combined-args doconly
722 (specializers (cl--generic-method-specializers method)) 722 (specializers (cl--generic-method-specializers method))
723 (non-default nil)
723 (met-name (cons symbol specializers)) 724 (met-name (cons symbol specializers))
724 (file (find-lisp-object-file-name met-name 'cl-defmethod))) 725 (file (find-lisp-object-file-name met-name 'cl-defmethod)))
726 (dolist (item specializers)
727 ;; default method has all 't' in specializers
728 (setq non-default (or non-default (not (equal t item)))))
729
725 (when (and file 730 (when (and file
726 (or specializers ;; default method has null specializers 731 (or non-default
727 (nth 2 info))) ;; assuming only co-located default has null doc string 732 (nth 2 info))) ;; assuming only co-located default has null doc string
728 (if specializers 733 (if specializers
729 (let ((summary (format elisp--xref-format-extra 'cl-defmethod symbol (nth 1 info)))) 734 (let ((summary (format elisp--xref-format-extra 'cl-defmethod symbol (nth 1 info))))
@@ -800,6 +805,7 @@ non-nil result supercedes the xrefs produced by
800(declare-function project-current "project") 805(declare-function project-current "project")
801 806
802(defun elisp--xref-find-references (symbol) 807(defun elisp--xref-find-references (symbol)
808 "Find all references to SYMBOL (a string) in the current project."
803 (cl-mapcan 809 (cl-mapcan
804 (lambda (dir) 810 (lambda (dir)
805 (xref-collect-references symbol dir)) 811 (xref-collect-references symbol dir))