Merge release Beta 1 into stable #21
1 changed files with 11 additions and 0 deletions
|
@ -27,6 +27,17 @@
|
|||
res#
|
||||
~else)))
|
||||
|
||||
;; Todo: Test this properly and if working, replace when-else with this
|
||||
;; Todo: find a way to download clojure documentation for offline use
|
||||
(defmacro when-else2
|
||||
"Evaluates [tst], if it's truthy value returns that value.
|
||||
If it's not, execute everything in [else] and return last expr."
|
||||
[tst & else]
|
||||
`(let [res# ~tst]
|
||||
(if res#
|
||||
res#
|
||||
(do ~@else))))
|
||||
|
||||
(defmacro ret=
|
||||
"compares two values using [=]. If the result is true
|
||||
returns the value, else the result of [=].
|
||||
|
|
Loading…
Reference in a new issue