Get QSharedPointer's Reference Count
Can someone share the code for getting the reference count using QSharedPointer?
There is no code to share as its not part of the public interface.
The link talks about subclassing QSharedPointer to make the info
Can I ask why you need this info ?
Thanks for your reply.
The reason I ask this is that std::shared_ptr has a API for getting the reference count..
And, for the purpose of understanding also, we need to know when the reference count was decreased, what made it decrease etc...
Well if feel for it, you can add such info to the class yourself, maybe with extra debug information.
or simply use std::shared_ptr
Give it a day or two. I think other might have good idea regarding this :)