Hi Dan,

Did anybody come up with a good way to generalize a collect protocol 
using higher order functions? It seems to me from a performance 
perspective there's two cases if you're dealing with non-lazy 
collections: one where the size of the output collection is known 
beforehand (map,concat etc..) and one where it's built incrementally 
(subset).

And is there a good way of doing an iterate->collect without essentially 
maintaining two cursors underneath? (unless you generalize the concept 
of a cursor ;-)

Also, maybe the term 'sequence' could be renamed to something else, 
since the sequence protocol currently describes a random access structure.

(Sorry I'm all questions and no answers at the moment)

Cheers,

Phil



Daniel Ehrenberg wrote:
> On Thu, Mar 27, 2008 at 10:22 PM, Eduardo Cavazos
> <[EMAIL PROTECTED]> wrote:
>>  Here's a sketch:
>>
>>         http://dharmatech.onigirihouse.com/seq-iter.factor
>>
>>  The 'newfx' vocab is at:
>>
>>         http://dharmatech.onigirihouse.com/newfx.factor
>>
>>  Yes, it's heretical.
> 
> Regardless of whether it's heretical, I don't understand why you
> decided to design it this way. I'm wondering what the advantages of a
> cursor-based approach over a higher order function are, and of
> including the quotation in the iterator. Or are you imagining this
> iterator thing just as a cleaner implementation of find, rather than a
> way to make sequences more generic?
> 
> Dan
> 
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
> _______________________________________________
> Factor-talk mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/factor-talk
> 



-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Factor-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to