Subject: Re: [boost] [GSOC] Regarding the project Boost.DeVector
From: Thomas Klimpel (Thomas.Klimpel_at_[hidden])
Date: 2009-04-04 09:32:04
Mathias Gaunard on March 30 wrote:
> Satyam Shekhar wrote:
> > But would it be worthwhile to
> > modify Boost.Iterator itself and define new concepts using segmentedness as
> > another orthogonal category, and then modify iterator_facade to support it?
> > One of the factors influencing this would obviously be whether segmented
> > iterators are going to be used widely in the future for other containers.
> segmented iterators can also be used to iterate through recursive
> structures, such as trees, if I understood what I read on the subject
On a second thought (while deleting old mail...), this statement is misleading for several reasons:
1) A "normal" non-segmented iterator is perfectly able to iterate through recursive structures, such as trees.
2) A segmented iterator would be more efficient for "compile-time" recursice structures, but for "run-time" recursive structures, it would just fall back to the behavior (and efficiency) of a "normal" non-segmented iterator.
3) The "real" efficiency advantage of segmented iterators will normally come from the "inner-most" iteration, so whether a given recursive data structure will gain something by providing segmented-iterators will only depend on whether it is possible to provide a more efficient "inner-most" iteration for that data structure than without segmented iterators.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk