2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-22 17:32:55 +00:00

Add != overload for shared ptr (Tru64 compiler lib seems to use it)

[SVN r20428]
This commit is contained in:
Raoul Gough
2003-10-20 15:49:50 +00:00
parent 2daf80f91e
commit 7482040832

View File

@@ -23,6 +23,7 @@
typedef boost::shared_ptr<int_wrapper> int_wrapper_holder;
bool operator< (int_wrapper_holder const &, int_wrapper_holder const &);
bool operator== (int_wrapper_holder const &, int_wrapper_holder const &);
bool operator!= (int_wrapper_holder const &, int_wrapper_holder const &);
#include <boost/python/suite/indexing/container_suite.hpp>
#include <vector>
@@ -45,6 +46,11 @@ bool operator== (int_wrapper_holder const &lhs, int_wrapper_holder const &rhs)
return (*lhs) == (*rhs);
}
bool operator!= (int_wrapper_holder const &lhs, int_wrapper_holder const &rhs)
{
return (*lhs) != (*rhs);
}
BOOST_PYTHON_MODULE(test_vector_shared_ext)
{
boost::python::implicitly_convertible <int, int_wrapper>();