
Hello, I use intrusive_ptr with a class that holds the refcount and I derive from that class all my other classes. class TObject { public : int refcount ; TObject () { refcount = 0;} } I have defined the intrusive_..._addref and _release to increase and decrease/delete that refcount and everything works good! Anywhay sometimes I need to assign a derived object to another derived object of the same type instrusive_ptr <Derived> A = new Derived; . . . the problem: *A = *Derived(constr parameters). The point is that the refcount is assigned too (and becames 0) How are instrusive_addref and _release supposed to be implemented ? Any quick and clean solution for that ? I cannot write assignment operator for every derived class because... there are a lot of members :) Really thanks! Thomas