Function: neocaml--subtree-text
neocaml--subtree-text is a natively compiled function defined in
neocaml.el.
Signature
(neocaml--subtree-text NODE TYPE &optional DEPTH)
Documentation
Return the text of the first TYPE child in NODE's subtree.
Search up to DEPTH levels deep (default 1). Return nil if not found.
Source Code
;; Defined in /nix/store/ahssdx4rwzyxhyhavpn0bkznk13xrggi-emacs-packages-deps/share/emacs/site-lisp/elpa/neocaml-20260907.2015/neocaml.el
(defun neocaml--subtree-text (node type &optional depth)
"Return the text of the first TYPE child in NODE's subtree.
Search up to DEPTH levels deep (default 1). Return nil if not found."
(when-let* ((child (treesit-search-subtree node type nil nil (or depth 1))))
(treesit-node-text child t)))