Function: cider-xref-tree--impl-node

cider-xref-tree--impl-node is a byte-compiled function defined in cider-xref-tree.el.

Signature

(cider-xref-tree--impl-node DICT)

Documentation

Return a tree node for one protocol-impl DICT from the op.

Jumps to the impl's own source location when the op resolved a real one, else falls back to looking the name up via cider-find-var.

Source Code

;; Defined in ~/.emacs.d/elpa/cider-20260822.1520/cider-xref-tree.el
(defun cider-xref-tree--impl-node (dict)
  "Return a tree node for one protocol-impl DICT from the op.
Jumps to the impl's own source location when the op resolved a real one, else
falls back to looking the name up via `cider-find-var'."
  (let ((name (nrepl-dict-get dict "name"))
        (file (nrepl-dict-get dict "file-url"))
        (line (nrepl-dict-get dict "line")))
    (if (and file (not (cider--tooling-file-p file)))
        (cider-tree-view-node-create
         :label (cider-font-lock-as-clojure name)
         :on-visit (lambda () (cider-xref-tree--jump-to-file file line)))
      (cider-xref-tree--name-node name))))