cgrand / xforms

Extra transducers and reducing fns for Clojure(script)
575 stars 32 forks source link

transjuxt not working in cljs? #13

Closed den1k closed 7 years ago

den1k commented 7 years ago

This example from README throws an arity error in cljs.

(into {} (x/by-key odd? (x/transjuxt [(x/reduce +) x/avg])) (range 256))

=>
#object[Error Error: Invalid arity: 3]
Error: Invalid arity: 3
    at cljs.core.pr_str.call.net.cgrand.xforms.transjuxt.cljs$core$IFn$_invoke$arity$1.net.cgrand.xforms.reduce.call.net.cgrand.xforms.t_net$cgrand$xforms36641.G__36724 [as call] (eval at figwheel$client$utils$eval_helper (http://localhost:8080/js/compiled/out/figwheel/client/utils.js:143:8), <anonymous>:4251:7)
...
cgrand commented 7 years ago

A shorter case is (into [] (x/transjuxt [identity]) [0]). I won't be able to look into for about the next 10 days.

cgrand commented 7 years ago

0.9.2 pushed to closers with this fix