Boost logo

Boost :

Subject: [boost] Is there something like shared_array<T> but with iterators?
From: david.hagood_at_[hidden]
Date: 2014-10-14 11:00:22


I am doing signal processing, and in order to avoid data copies I need
something that:
1) can adopt a buffer of data (e.g. take ownership of a T*)
2) Release that buffer via an appropriate method (e.g. take a deallocator
object).
3) Provide operator[] over that buffer
4) provide shared ownership semantics

So far, that's shared_array<> to a T [sic]

However, I need one more thing:

5) provide iterator support (begin(), end(), cbegin(), cend())

The current shared_array<> doesn't provide that - is there anything else
that does?


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