Re: Various comments Rob Mayoff 02 May 2003 07:00 UTC

+---------- On May 1, xxxxxx@freenetproject.org said:
> The short answer is that while an iterator can easily be functional and
> efficient (because it usually only needs a small amount of state, like a
> pointer), a datastructure may not be.  Take as an example an actively
> balanced tree.  A functional version of remove may have to do a lot of
> work to modify the tree, but even more if its not allowed to affect the
> original (possibly as bad as copying the entire tree).  At best this
> creates a lot of extra GC pressure.

Having only functional iterators creates often-needless GC pressure.
Please add iterator-next! so we can iterate over our collections without
undue consing.