
20 Dec
2011
20 Dec
'11
8:02 p.m.
On Tuesday, December 20, 2011 2:54 PM, Jayden Shui wrote:
It is just my guess. In fact I need MIC with shared_ptr to a scoped_ptr. The shared_ptr is used to count number of uses, while the scoped_ptr used to handle polymorphic objects. I feel a little nervous with that.
There should be no need for both pointer types. Shared_ptr handles polymorphic objects just fine. A MIC holding shared_ptrs to your base class should do what you need, and the overhead associated with the shared_ptr should be negligible.