Fix boost intrusive_ptr testcase compilation with latest boost/gcc
This commit is contained in:
parent
bdf98744b1
commit
52858d5353
1 changed files with 6 additions and 9 deletions
|
|
@ -13,9 +13,12 @@
|
|||
%warnfilter(SWIGWARN_LANG_SMARTPTR_MISSING) KlassDerived;
|
||||
%warnfilter(SWIGWARN_LANG_SMARTPTR_MISSING) KlassDerivedDerived;
|
||||
|
||||
%inline %{
|
||||
#include "boost/shared_ptr.hpp"
|
||||
#include "boost/intrusive_ptr.hpp"
|
||||
%{
|
||||
template<typename T> void intrusive_ptr_add_ref(const T* r) { r->addref(); }
|
||||
template<typename T> void intrusive_ptr_release(const T* r) { r->release(); }
|
||||
|
||||
#include <boost/shared_ptr.hpp>
|
||||
#include <boost/intrusive_ptr.hpp>
|
||||
#include <boost/detail/atomic_count.hpp>
|
||||
|
||||
// Uncomment macro below to turn on intrusive_ptr memory leak checking as described above
|
||||
|
|
@ -102,8 +105,6 @@
|
|||
|
||||
%ignore IgnoredRefCountingBase;
|
||||
%ignore *::operator=;
|
||||
%ignore intrusive_ptr_add_ref;
|
||||
%ignore intrusive_ptr_release;
|
||||
%newobject pointerownertest();
|
||||
%newobject smartpointerpointerownertest();
|
||||
|
||||
|
|
@ -430,10 +431,6 @@ template <class T1, class T2> struct Pair : Base<T1, T2> {
|
|||
Pair<int, double> pair_id2(Pair<int, double> p) { return p; }
|
||||
SwigBoost::intrusive_ptr< Pair<int, double> > pair_id1(SwigBoost::intrusive_ptr< Pair<int, double> > p) { return p; }
|
||||
|
||||
template<typename T> void intrusive_ptr_add_ref(const T* r) { r->addref(); }
|
||||
|
||||
template<typename T> void intrusive_ptr_release(const T* r) { r->release(); }
|
||||
|
||||
long use_count(const SwigBoost::shared_ptr<Space::Klass>& sptr) {
|
||||
return sptr.use_count();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue