-
-
Save tomjack/78d8bcf9f2753e2f85ed to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(fn reducer [coll xf] | |
(reify | |
cljs.core/IReduce | |
(-reduce [this f1] | |
(-reduce this f1 (f1))) | |
(-reduce [_ f1 init] | |
(-reduce coll (xf f1) init)))) | |
(fn folder [coll xf] | |
(reify | |
cljs.core/IReduce | |
(-reduce [_ f1] | |
(-reduce coll (xf f1) (f1))) | |
(-reduce [_ f1 init] | |
(-reduce coll (xf f1) init)))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment