-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Thank you for your answer. I know that intrusive_ptr is not documented yet. But in documentation of weak_ptr is written that when all shared_ptr are destroyed all weak_ptr are set to 0. And it of course works in that style for normal shared pointer. But when I am using weak_ptr with intrusive_ptr it know works like normal pointer? I think I missed something. Is it bug or feature? Thank yo for your answer.
You can't call it a bug until there's documentation which tells you what you have a right to expect ;-)
In this case, it's not a bug. You can implement the dispose() function on your class to throw away resources when the last shared_ptr reference goes away, but weak_ptr references still exist.
- -- Petr "Fers" Ferschmann -=[ petr@ferschmann.cz ]==[ http://petr.ferschmann.cz/ ]=- - -=[ Koukni na http://www.postcard.cz/ ]==[ +420 604/781 009 ]=- GPG Fingerprint: [83B0 6378 7A9D D993 035E 60BD FEEC F665 D2C8 1B9A] -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (GNU/Linux) iD4DBQE9mZmp/uz2ZdLIG5oRAm+OAJi1LRmqGWCZvtavAc+mhykBu+YBAJ9BjYFS 6PKKvbL7QrP/B20H9FZ/2g== =st3J -----END PGP SIGNATURE-----