When a StrBlob
object is destroyed, the shared pointer member is destroyed by calling the pointer's destructor, thus decreasing the reference count of the shared pointer, if the count is zero, then the vector pointed by the smart pointer is destroyed too.
When a StrBlobPtr
object is destroyed, the weak pointer member is destroyed by calling the pointer's destructor, the vector pointed by the smart pointer is not affected.