macro | since v0.0-927 | imported clojure.core/while | Edit |
(while test & body)
Repeatedly executes body
while test
expression is true. Presumes some
side-effect will cause test
to become false or nil.
Returns nil.
Repeatedly executes body while test expression is true. Presumes some side-effect will cause test to become false/nil. Returns nil
(defmacro while
{:added "1.0"}
[test & body]
`(loop []
(when ~test
~@body
(recur))))