On Iteration

BLS windevguy at hotmail.de
Tue Nov 10 07:07:51 PST 2009


On 10/11/2009 11:18, Lutger wrote:
> Andrei Alexandrescu wrote:
>
>> I consider changing a bit D's range model following the better
>> understanding reflected in this article:
>>
>> http://erdani.com/publications/on-iteration.html
>>

Very good read.

> - how to do ranges over a tree?
> My first thought was that a tree would define preorder / inorder / postorder
> ranges, and then perhaps visitors for more complex algorithms.


I asked the same question quit a while ago... I think we have to imagine 
a tree's branch as sub range. ( In other words, treat them like linear 
structures)

How to implement it? I dunno.

IMO it would make sense to implement some basic data structures for 
std.mutable.dtl. (Tree like structures) ...not production ready,  just 
as Range "proof of product" test.

atm I am implementing  two of them : skip lists and left leaning rb 
trees.  Would be nice to have some support btw.








More information about the Digitalmars-d mailing list