Rework $ operator to work like applicative in Haskell
f $ g $ h -> f(g(h)) whereas previous implementation ($ f g h) was h(g(f)).
This commit is contained in:
@@ -82,7 +82,7 @@ arguments `LAMBDA-LIST' with body `BODY'."
|
|||||||
"Given a sequence of FORMS, return a unary function which applies each form
|
"Given a sequence of FORMS, return a unary function which applies each form
|
||||||
sequentially"
|
sequentially"
|
||||||
`(lambda (x)
|
`(lambda (x)
|
||||||
(->> x ,@forms)))
|
(->> x ,@(reverse forms))))
|
||||||
|
|
||||||
(defmacro alist-val (key alist)
|
(defmacro alist-val (key alist)
|
||||||
"Helper macro for getting the value of KEY in ALIST."
|
"Helper macro for getting the value of KEY in ALIST."
|
||||||
|
|||||||
Reference in New Issue
Block a user