We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f48aacf commit b28d586Copy full SHA for b28d586
1 file changed
include/boost/python/handle.hpp
@@ -81,7 +81,12 @@ class handle
81
{
82
}
83
84
- handle& operator=(handle const& r);
+ handle& operator=(handle const& r)
85
+ {
86
+ python::xdecref(m_p);
87
+ m_p = python::xincref(r.m_p);
88
+ return *this;
89
+ }
90
91
#if !defined(BOOST_MSVC) || (BOOST_MSVC > 1200)
92
@@ -189,14 +194,6 @@ inline handle<T>::~handle()
189
194
python::xdecref(m_p);
190
195
191
196
192
-template <class T>
193
-inline handle<T>& handle<T>::operator=(handle<T> const& r)
-{
- python::xdecref(m_p);
- m_p = python::xincref(r.m_p);
197
- return *this;
198
-}
199
-
200
template <class T>
201
inline T* handle<T>::operator->() const
202
0 commit comments