seq fns promoted to clojure.core!

7 views
Skip to first unread message

Stuart Halloway

unread,
Apr 28, 2010, 4:01:04 PM4/28/10
to clo...@googlegroups.com
Several clojure.contrib.seq/seq-utils functions have been promoted
(with some modification) to clojure.core.

Here's the super-terse summary from the code comment:

;; moved to clojure.core: flatten, partition-all, frequencies,
;; reductions, shuffle, partition-by
;; moved with semantic changes:
;; group-by now returns an *unsorted* map
;; moved with name changes:
;; rand-elt => clojure.core/rand-nth
;; includes? => clojure.core/seq-contains?

I am standing by in IRC to answer questions you may have, and will be
following this email one with a longer one detailing the rationale for
these changes.

Thanks!

Stu

--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clo...@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+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

liebke

unread,
Apr 28, 2010, 7:43:37 PM4/28/10
to Clojure
Unfortunately, group-by is a commonly used function name, used in both
Incanter and swank-clojure. I've renamed Incanter's group-by to group-
on, but the naming conflict of clojure.core/group-by and swank-
clojure.util/group-by is preventing swank from starting up using
either lein swank or the swank scripts included with Labrepl and
Incanter. I'm dead in the water, any suggested work arounds?

David

Phil Hagelberg

unread,
Apr 28, 2010, 7:46:14 PM4/28/10
to clo...@googlegroups.com
On Wed, Apr 28, 2010 at 4:43 PM, liebke <lie...@gmail.com> wrote:
> Unfortunately, group-by is a commonly used function name, used in both
> Incanter and swank-clojure. I've renamed Incanter's group-by to group-
> on, but the naming conflict of clojure.core/group-by and swank-
> clojure.util/group-by is preventing swank from starting up using
> either lein swank or the swank scripts included with Labrepl and
> Incanter. I'm dead in the water, any suggested work arounds?

I just pushed an fixed swank to clojars a few minutes ago; this should
solve the issue. Swank's old definition is basically the same as the
one in core modulo some transient use, so swank now falls back to its
own definition only if it's not defined in clojure.core.

-Phil

Stuart Halloway

unread,
Apr 28, 2010, 7:50:23 PM4/28/10
to clo...@googlegroups.com
One option is to configure lein to use a specific timestamp instead of
snapshot. Then you can back off the edge a little.

Stu

Phil Hagelberg

unread,
Apr 28, 2010, 7:54:55 PM4/28/10
to clo...@googlegroups.com
On Wed, Apr 28, 2010 at 4:50 PM, Stuart Halloway
<stuart....@gmail.com> wrote:
> One option is to configure lein to use a specific timestamp instead of
> snapshot. Then you can back off the edge a little.

Yeah, using Clojure version "1.2.0-master-20100426.160114-46" would
allow you to hold off on bringing in the changes until you have time
to devote to tracking down breakages. The matching contrib version is
"1.2.0-20100427.200505-82".

This works for Leiningen, Maven, Ivy, etc; anything that uses the
maven repository format.

-Phil
Reply all
Reply to author
Forward
0 new messages