Function: nrepl-dbind-response
nrepl-dbind-response is a macro defined in nrepl-dict.el.
Signature
(nrepl-dbind-response RESPONSE KEYS &rest BODY)
Documentation
Destructure an nREPL RESPONSE dict.
Bind the value of the provided KEYS and execute BODY.
Source Code
;; Defined in ~/.emacs.d/elpa/cider-20260822.1520/nrepl-dict.el
;;; Destructuring-bind of string keys
(defmacro nrepl-dbind-response (response keys &rest body)
"Destructure an nREPL RESPONSE dict.
Bind the value of the provided KEYS and execute BODY."
(declare (debug (form (&rest symbolp) body)))
(let ((response-var (gensym "response")))
`(let* ((,response-var ,response)
,@(mapcar (lambda (key)
`(,key (nrepl-dict-get ,response-var ,(format "%s" key))))
keys))
,@body)))