Have you considered taking a function that will produce the
collection?

(map-queue odd? #(range 1 10) :queue-size 5)

and in your function of course, (doseq [value (coll)]

So that there's no intermediary holding on to the head. Making your
function a macro would perhaps clean it up a bit so client code can
just put a form and you code the more clear form (fn [] ...) This
seems to me preferable than depending on the compiler wits since the
head rule is pretty clear but being up to date in the latest compiler
features (and possible regressions) is more difficult.

-- 
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

Reply via email to