Boost logo

Boost :

From: Thorsten Ottosen (nesotto_at_[hidden])
Date: 2004-11-09 17:34:33

"Robert Ramey" <ramey_at_[hidden]> wrote in message
| "John Torjo" <john.lists_at_[hidden]> wrote in message
| example 1
| > >>It makes dealing with containers/STL algorithms simpler by using ranges
| > >>(as opposed to iterators).

| Attached is the equivalent code using iterators.
| It includes code to add templeted constructors to iterators and to make
| functors for this particular example. Otherwise its very similar in
| functionality. And that is my point. I don't see that ranges are anything
| more than a very thin layer over iterators. Admitidly, iterators could
| perhaps use some embellishment (perhaps templated constructors) or other
| things to make them easier to use, but I don't think a whole now layer/view
| is warrented. I would prefer to see such efforts invested in making
| iterators easier to use without hidind their essential character.

If you are going to convince me iterators are easy to use, you have to come up
with something better than

    typedef amended::transform_iterator<
> romanian_names_t;

        std::ostream_iterator<std::string>(std::cout," ")

Seriously, this is so ugly and hard to write that I predict less than 1% of
the community will ever use it.


Boost list run by bdawes at, gregod at, cpdaniel at, john at