Function: eglot-signature-eldoc-function
eglot-signature-eldoc-function is a byte-compiled function defined in
eglot.el.gz.
Signature
(eglot-signature-eldoc-function CB)
Documentation
A member of eldoc-documentation-functions, for signatures.
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/eglot.el.gz
(defun eglot-signature-eldoc-function (cb)
"A member of `eldoc-documentation-functions', for signatures."
(when (eglot-server-capable :signatureHelpProvider)
(let ((buf (current-buffer)))
(jsonrpc-async-request
(eglot--current-server-or-lose)
:textDocument/signatureHelp (eglot--TextDocumentPositionParams)
:success-fn
(eglot--lambda ((SignatureHelp)
signatures activeSignature (activeParameter 0))
(eglot--when-buffer-window buf
(let ((active-sig (and (cl-plusp (length signatures))
(aref signatures (or activeSignature 0)))))
(if (not active-sig) (funcall cb nil)
(funcall
cb (mapconcat (lambda (s)
(eglot--sig-info s (and (eq s active-sig)
activeParameter)
nil))
signatures "\n")
:echo (eglot--sig-info active-sig activeParameter t))))))
:deferred :textDocument/signatureHelp))
t))