Skip to content

clojure.core/cond->

View this page on ClojureDocs

Type: macro Added: Clojure 1.5 Examples: 7 Runnable: 4
([expr & clauses])

Takes an expression and a set of test/form pairs. Threads expr (via ->) through each form for which the corresponding test expression is true. Note that, unlike cond branching, cond-> threading does not short circuit after the first true test expression.

Examples

by avasenin on
by arichiardi on . May have evaluation errors.
by trikitrok on . May have evaluation errors.
by mhmdsalem1993 on
by reborg on . May have evaluation errors.
by rainbyte on
by daveliepmann on

See also


Content from the matching ClojureDocs page, with authors credited on each contribution.