Function: combobulate-walk-tree-1

combobulate-walk-tree-1 is a natively compiled function defined in combobulate-navigation.el.

Signature

(combobulate-walk-tree-1 TREE NODE-FN LEAF-FN RESULT-FN DEPTH)

Source Code

;; Defined in /nix/store/b5fvrwzi3zvkabyzx0in6gw1cj963z46-emacs-packages-deps/share/emacs/site-lisp/combobulate-navigation.el
(defun combobulate-walk-tree-1 (tree node-fn leaf-fn result-fn depth)
  (pcase tree
    ;; ((guard (and (consp tree)
    ;;              (atom (car tree))
    ;;              (null (cdr tree))))
    ;;  (funcall leaf-fn tree depth))
    ((pred combobulate-node-p)
     (funcall node-fn tree depth))
    (`(,left . ,right)
     (catch 'skip
       (funcall result-fn
                (combobulate-walk-tree-1 left node-fn leaf-fn result-fn (1+ depth))
                (combobulate-walk-tree-1 right node-fn leaf-fn result-fn depth))))))