Boost logo

Boost :

From: Roland Schwarz (roland.schwarz_at_[hidden])
Date: 2008-05-24 06:47:00

After having read

I have been left, believing that the new iterator concepts will
allow me to create an iterator that may return a proxy instead
of a reference.

I tried to do this by using the iterator_facade template, and
for the "Reference" parameter I specified a proxy class
that has a conversion operator to the "Value" type.

This almost works, but fails for expressions of

Val v = it[n];

expressions, because iterator facade does not return "Reference"
objects in that case, but operator_brackets_proxy objects that
are convertible to "Reference".

So I am wondering if I understand something wrong? Isn't the
decoupling of access and traversal meant to allow "Reference" be
a proxy object?

Any hints appreciated!

  _  _  | Roland Schwarz
 |_)(_  | aka. speedsnail
 | \__) | mailto:roland.schwarz_at_[hidden]

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