Hi all,

in the following, set is clojure.set, and r is clojure.core reducers.

Why is

    user> (reduce set/intersection (map set [[1 2] [3 1] [1 3]]))
    #{1}

but

    user> (reduce set/intersection (r/map set [[1 2] [3 1] [1 3]]))
    ArityException Wrong number of args (0) passed to: set$intersection
    clojure.lang.AFn.throwArity (AFn.java:437)

The clojure.core/reduce docs state that when there's no init value, the
reduce function is called with the first two elements of the coll.

The behavior of calling the reduce function with no arguments to create
an init value is specified for r/reduce, but I'm not using that.

Is that a bug, or should I not expect that clojure.core/reduce works
with reducible collections?  (I've not followed which reducer changes
were made in clojure 1.5.1.)

Bye,
Tassilo

-- 
-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to