Function: dape--variables-recursive
dape--variables-recursive is a natively compiled function defined in
dape.el.
Signature
(dape--variables-recursive CONN OBJECT PATH PRED CB)
Documentation
Update variables recursivly.
Get variable data from CONN and put result on OBJECT until PRED is nil.
PRED is called with PATH and OBJECT.
See dape-request for expected CB signature.
Source Code
;; Defined in /nix/store/1fiaif8pifqj2jh65rbg3fkhg3i56q42-emacs-packages-deps/share/emacs/site-lisp/elpa/dape-0.27.1/dape.el
(defun dape--variables-recursive (conn object path pred cb)
"Update variables recursivly.
Get variable data from CONN and put result on OBJECT until PRED is nil.
PRED is called with PATH and OBJECT.
See `dape-request' for expected CB signature."
(if-let* ((objects
(cl-loop
for variable in (or (plist-get object :scopes)
(plist-get object :variables))
for name = (plist-get variable :name)
for expensive-p = (eq (plist-get variable :expensive) t)
when (and (not expensive-p) (funcall pred (cons name path)))
collect variable)))
(let ((responses 0))
(dolist (object objects)
(dape--with-request (dape--variables conn object)
(dape--with-request
(dape--variables-recursive
conn object (cons (plist-get object :name) path) pred)
(when (length= objects (cl-incf responses))
(dape--request-continue cb))))))
(dape--request-continue cb)))