Namespace: joker.better-cond
v1.0Contents
Summary
A collection of variations on Clojure's core macros.
Index
Constants
Constants are variables with :const true in their metadata. Joker currently does not recognize them as special; as such, it allows redefining them or their values.-
(None.)
Variables
-
(None.)
Functions, Macros, and Special Forms
-
cond
Macro v1.0(cond & clauses)
A variation on cond which sports let bindings, do and implicit else:
source
(cond
(odd? a) 1
:do (println a)
:let [a (quot a 2)]
(odd? a) 2
3).
Also supports :when-let and :when-some.
:let, :when-let, :when-some and :do do not need to be written as keywords. -
if-let
Macro v1.0(if-let bindings then)
(if-let bindings then else)
A variation on if-let where all the exprs in the bindings vector must be true.
source
Also supports :let. -
if-some
Macro v1.0(if-some bindings then)
(if-some bindings then else)
A variation on if-some where all the exprs in the bindings vector must be non-nil.
source
Also supports :let. -
when-let
Macro v1.0(when-let bindings & body)
A variation on when-let where all the exprs in the bindings vector must be true.
source
Also supports :let. -
when-some
Macro v1.0(when-some bindings & body)
A variation on when-some where all the exprs in the bindings vector must be non-nil.
source
Also supports :let.