Boost logo

Boost :

Subject: Re: [boost] RFC: A better shared_array
From: Olaf van der Spek (ml_at_[hidden])
Date: 2011-10-19 17:47:59

On Wed, Oct 19, 2011 at 11:42 PM, Rhys Ulerich <rhys.ulerich_at_[hidden]> wrote:
>>> ForwardRange.  To have shared_range::operator= logically accomplish
>>> the same thing, I opted for it copy a ForwardRange but not to perform
>>> any shared resource ownership.  In that case, the shared_array
>>> shared_range::p_ has no well-defined semantic (since nothing's
>>> managed) which makes data() (among other things) not well-defined
>>> concepts.  Consequently, no data() member nor any access to the
>> data() would just return empty() ? NULL : &front();
> You just implemented begin().  It's a range. :)

No, data() returns a pointer, while begin() returns an iterator (which
might be, but doesn't have to be, a pointer).


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