Boost logo

Boost :

From: Jeremy Siek (jsiek_at_[hidden])
Date: 2001-03-28 13:25:45


On Wed, 28 Mar 2001, Gary Powell wrote:
Gary.P>
Gary.P> What do you think about container trait concepts?

The Graph library already uses a very primitive and incomplete container
traits (see boost/pending/container_traits.hpp). I've been meaning to
continue this work, but other things had higher priority. Also, Austern
wrote a C++ article about container traits.

As for the new iterator traits... the code in boost/development/iterator
does not yet match my paper to the C++ committee, it needs to be updated.
I'll try to get to it in the next few days, unless Gary wants to go ahead
and make the changes.

Gary.P> Yes, but because VTL creates these iterators with the "correct tag", as in
Gary.P> the one from the iterator that is created, and we use that tag to make the
Gary.P> necessary interface. You lose "rbegin(), rend(), operator[](), at(),
Gary.P> back()" with only a input_iterator_tag. It also means that algorithms will
Gary.P> not select the most efficient operations, e.g. advance will call ++iterator
Gary.P> repeatedly instead of iterator += etc.

Right, and this problem is not particular to VTL. It affects lots of
iterators and std algorithms.

Cheers,
Jeremy

----------------------------------------------------------------------
 Jeremy Siek www: http://www.lsc.nd.edu/~jsiek/
 Ph.D. Candidate email: jsiek_at_[hidden]
 Univ. of Notre Dame work phone: (219) 631-3906
----------------------------------------------------------------------


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk