Re: Am I "holding on to the head" here ?

2009-02-09 Thread Jeffrey Straszheim
Cool, thanks. On Mon, Feb 9, 2009 at 7:14 AM, Rich Hickey wrote: > > > > On Feb 8, 5:13 pm, Jeffrey Straszheim > wrote: > > I have this piece of code: > > > > (defn- run-work-elements-in-parallel > > "Runs a group of work elements in parallel. Returns an extended > database." > > [elements

Re: Am I "holding on to the head" here ?

2009-02-09 Thread Rich Hickey
On Feb 8, 5:13 pm, Jeffrey Straszheim wrote: > I have this piece of code: > > (defn- run-work-elements-in-parallel > "Runs a group of work elements in parallel. Returns an extended database." > [elements database] > (assert (set elements)) > (let [[rec simp] (separate :recursive element

Re: Am I "holding on to the head" here ?

2009-02-08 Thread Jeffrey Straszheim
You're probably correct, but I'm still interested in the question in the more general sense. On Sun, Feb 8, 2009 at 5:17 PM, Kevin Downey wrote: > > I am not sure exactly how preduce differs from normal reduce, but > reduce is not a lazy operation, so it will result in the realization > of a laz

Re: Am I "holding on to the head" here ?

2009-02-08 Thread Kevin Downey
I am not sure exactly how preduce differs from normal reduce, but reduce is not a lazy operation, so it will result in the realization of a lazy seq passed to it. On Sun, Feb 8, 2009 at 2:13 PM, Jeffrey Straszheim wrote: > I have this piece of code: > > (defn- run-work-elements-in-parallel > "

Am I "holding on to the head" here ?

2009-02-08 Thread Jeffrey Straszheim
I have this piece of code: (defn- run-work-elements-in-parallel "Runs a group of work elements in parallel. Returns an extended database." [elements database] (assert (set elements)) (let [[rec simp] (separate :recursive elements) results-simp (pmap #(run-simple-work-element % data