Function: eglot--workspace-symbols
eglot--workspace-symbols is a byte-compiled function defined in
eglot.el.gz.
Signature
(eglot--workspace-symbols PAT &optional BUFFER)
Documentation
Ask for :workspace/symbol on PAT, return list of formatted strings.
If BUFFER, switch to it before.
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/eglot.el.gz
(defun eglot--workspace-symbols (pat &optional buffer)
"Ask for :workspace/symbol on PAT, return list of formatted strings.
If BUFFER, switch to it before."
(with-current-buffer (or buffer (current-buffer))
(eglot-server-capable-or-lose :workspaceSymbolProvider)
(mapcar
(lambda (wss)
(eglot--dbind ((WorkspaceSymbol) name containerName kind) wss
(propertize
(format "%s%s %s"
(if (zerop (length containerName)) ""
(concat (propertize containerName 'face 'shadow) " "))
name
(propertize (alist-get kind eglot--symbol-kind-names "Unknown")
'face 'shadow))
'eglot--lsp-workspaceSymbol wss)))
(eglot--request (eglot--current-server-or-lose) :workspace/symbol
`(:query ,pat)))))