[smart_ptr] comparison of intrusive_ptr objects

Does anybody know why intrusive_ptr has ==, != and < operators, but the rest ones are missing (i.e. >, <=, >=)? It makes hard to use intrusive_ptr in generic code.

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Tuesday 29 September 2009, Dmitry Vinogradov wrote:
Does anybody know why intrusive_ptr has ==, != and < operators, but the rest ones are missing (i.e. >, <=, >=)? It makes hard to use intrusive_ptr in generic code.
Can't you use std::relops to get those? -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkrCBW0ACgkQ5vihyNWuA4WT7gCgvqs6h/nOnh2i+kaegRgSv548 A8gAn06BOTpXpQy28QWOfLubZHCCf0KG =KJNj -----END PGP SIGNATURE-----

AMDG Dmitry Vinogradov wrote:
Does anybody know why intrusive_ptr has ==, != and < operators, but the rest ones are missing (i.e. >, <=, >=)? It makes hard to use intrusive_ptr in generic code.
Generally, the convention is for generic code to use only <, ==, and !=. In Christ, Steven Watanabe

On Tue, Sep 29, 2009 at 8:12 AM, Dmitry Vinogradov <sraider@yandex.ru> wrote:
Does anybody know why intrusive_ptr has ==, != and < operators, but the rest ones are missing (i.e. >, <=, >=)? It makes hard to use intrusive_ptr in generic code.
Search for the subject line: Please don't define a fake"operator<"just for ordered containers" in the boost archives. ie starting at or around http://lists.boost.org/Archives/boost/2006/07/107267.php Make sure to continue into the next month, and the next,... Happy reading. Tony
participants (4)
-
Dmitry Vinogradov
-
Frank Mori Hess
-
Gottlob Frege
-
Steven Watanabe