Function: projectile--acond
projectile--acond is a macro defined in projectile.el.
Signature
(projectile--acond &rest CLAUSES)
Documentation
Like cond, but the result of each condition is bound to it.
The variable it is available within the remainder of each of CLAUSES.
CLAUSES are otherwise as documented for cond. This is copied from
anaphora.el.
Source Code
;; Defined in ~/.emacs.d/elpa/projectile-20260310.858/projectile.el
(defmacro projectile--acond (&rest clauses)
"Like `cond', but the result of each condition is bound to `it'.
The variable `it' is available within the remainder of each of CLAUSES.
CLAUSES are otherwise as documented for `cond'. This is copied from
anaphora.el."
(declare (debug cond))
(if (null clauses)
nil
(let ((cl1 (car clauses))
(sym (gensym)))
`(let ((,sym ,(car cl1)))
(if ,sym
(if (null ',(cdr cl1))
,sym
(let ((it ,sym)) ,@(cdr cl1)))
(projectile--acond ,@(cdr clauses)))))))