Function: clojure--form-descendants

clojure--form-descendants is a byte-compiled function defined in clojure-mode.el.

Signature

(clojure--form-descendants FORM TYPE &optional SKIP-QUOTED)

Documentation

Return the forms of TYPE in FORM, FORM included.

With SKIP-QUOTED, leave out the ones in quoted and syntax-quoted forms.

Source Code

;; Defined in ~/.emacs.d/elpa/clojure-mode-20261103.1226/clojure-mode.el
(defun clojure--form-descendants (form type &optional skip-quoted)
  "Return the forms of TYPE in FORM, FORM included.
With SKIP-QUOTED, leave out the ones in quoted and syntax-quoted forms."
  (unless (and skip-quoted (memq (clojure--form-type form) '(quote syntax-quote)))
    (let ((found (mapcan (lambda (child)
                           (clojure--form-descendants child type skip-quoted))
                         (clojure--form-children form))))
      (if (eq (clojure--form-type form) type)
          (cons form found)
        found))))