Boost logo

Boost :

From: Alan Bellingham (alan_at_[hidden])
Date: 2002-02-02 18:01:11

"Jani Kajala" <jani_at_[hidden]>:

>Why not auto_ptr to vector of auto_ptrs?

Because auto_ptr<> doesn't satisfy the requirements for being a
std::vector<> member?

(Now, an auto_ptr<> to vector<> of boost::shared_ptr<>, that's a
different matter.)

The proposal sounds simple and elegant. auto_ptr<>-style semantics may
be a little surprising - some might prefer something similar to the way
boost::shared_ptr<> works.

"Mark Rodgers" <mark.rodgers_at_[hidden]>:

>- Adds a release function (erase but return instead of
> destroy).

Is this the element or the vector we're talking about?

Also, does auto_vector<T>::operator[] return T&, or just T* as
std::vector<T*>::operator[] would.

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