Function: xref--analyze
xref--analyze is a byte-compiled function defined in xref.el.gz.
Signature
(xref--analyze XREFS)
Documentation
Find common groups in XREFS and format group names.
Return an alist of the form ((GROUP . (XREF ...)) ...).
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/xref.el.gz
(defun xref--analyze (xrefs)
"Find common groups in XREFS and format group names.
Return an alist of the form ((GROUP . (XREF ...)) ...)."
(let* ((alist
(xref--alistify xrefs
(lambda (x)
(xref-location-group (xref-item-location x)))))
(project (and
(eq xref-file-name-display 'project-relative)
(project-current)))
(project-root (and project
(expand-file-name (xref--project-root project)))))
(mapcar
(lambda (pair)
(cons (xref--group-name-for-display (car pair) project-root)
(cdr pair)))
alist)))