Boost logo

Boost :

From: Spencer Collyer (spencer_at_[hidden])
Date: 2006-04-27 06:30:03


On Thu, 27 Apr 2006 11:18:24 +0200, Robert Kawulak wrote:
> If I understand you correctly, you want the lower bound to be
> included in the allowed range, but the upper bound to be
> excluded. If so, then the Constrained Types library allows for
> such one-side-opened ranges (I hope I express myself precisely
> enough, I don't know math english that well ;-).

The upper bound has to be included as far as the class is concerned, so
that it can construct an end() iterator. However, the user cannot specify
the upper bound as a subscript.
> However, there may be a problem - the library is designed to work
> only with random access iterators. Does your library use random
> access iterators only or any kind of iterator is allowed?

Now I'm confused. My sparse_array class allows you to generate iterators
for accessing the elements in the sparse_array. I don't have iterators
over the subscript values, but over the array elements. I'm confused as
to why I would worry about the type of iterators your library is designed
to work with.

For what it's worth, the sparse_array iterators are random-access.


<<< Eagles may soar, but weasels don't get sucked into jet engines >>>
11:21am up 39 days 22:54, 22 users, load average: 0.22, 0.26, 0.45
Registered Linux User #232457 | LFS ID 11703

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