Boost logo

Boost :

From: Jeff Flinn (TriumphSprint2000_at_[hidden])
Date: 2004-07-30 08:26:37


"Jeff Flinn" <TriumphSprint2000_at_[hidden]> wrote in message
news:cedhqq$9ur$1_at_sea.gmane.org...
> Andrew,
>
> (I'm top posting since for some reason auto '>' for your original text is
> defeated with this particular message)
>
> One issue you mention is lifetime. I assume you have a either a CListCtrl
or
> CListView derived class. This class should have it's own
vector<shared_ptr>.
> Then the lifetime of the listview items is ensured.
>
> No you can NOT use a casted shared_ptr in this fashion. You can
> reinterpret_cast<DWORD_PTR>(&*my_shared_ptr) if you feel you must. This
will

Oops, use my_shred_ptr.get() as Jody mentioned.

-----------------
Jeff Flinn
Applied Dynamics, International


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