diff options
Diffstat (limited to 'libshiboken/conversions.h')
-rw-r--r-- | libshiboken/conversions.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libshiboken/conversions.h b/libshiboken/conversions.h index d6a3dd5e..afc4989f 100644 --- a/libshiboken/conversions.h +++ b/libshiboken/conversions.h @@ -99,7 +99,7 @@ struct CppObjectCopier<T, true> { static inline T* copy(const T& obj) { - return reinterpret_cast<T*>(BaseType::copy(reinterpret_cast<SbkBaseType*>(SbkType<T>()), &obj)); + return reinterpret_cast<T*>(BaseType::copy(reinterpret_cast<SbkObjectType*>(SbkType<T>()), &obj)); } }; @@ -113,7 +113,7 @@ inline PyObject* createWrapper(const T* cppobj, bool hasOwnership = false, bool const char* typeName = 0; if (!isExactType) typeName = typeid(*const_cast<T*>(cppobj)).name(); - return Wrapper::newObject(reinterpret_cast<SbkBaseType*>(SbkType<T>()), + return Wrapper::newObject(reinterpret_cast<SbkObjectType*>(SbkType<T>()), const_cast<T*>(cppobj), hasOwnership, isExactType, typeName); } @@ -213,7 +213,7 @@ struct ValueTypeConverter { if (PyObject_TypeCheck(pyobj, SbkType<T>())) return true; - SbkBaseType* shiboType = reinterpret_cast<SbkBaseType*>(SbkType<T>()); + SbkObjectType* shiboType = reinterpret_cast<SbkObjectType*>(SbkType<T>()); return BaseType::isExternalConvertible(shiboType, pyobj); } static inline PyObject* toPython(void* cppobj) { return toPython(*reinterpret_cast<T*>(cppobj)); } @@ -231,7 +231,7 @@ struct ValueTypeConverter static inline T toCpp(PyObject* pyobj) { if (!PyObject_TypeCheck(pyobj, SbkType<T>())) { - SbkBaseType* shiboType = reinterpret_cast<SbkBaseType*>(SbkType<T>()); + SbkObjectType* shiboType = reinterpret_cast<SbkObjectType*>(SbkType<T>()); if (BaseType::hasExternalCppConversions(shiboType) && isConvertible(pyobj)) { T* cptr = reinterpret_cast<T*>(BaseType::callExternalCppConversion(shiboType, pyobj)); std::auto_ptr<T> cptr_auto_ptr(cptr); @@ -271,7 +271,7 @@ struct ObjectTypeConverter { if (pyobj == Py_None) return 0; - SbkBaseType* shiboType = reinterpret_cast<SbkBaseType*>(pyobj->ob_type); + SbkObjectType* shiboType = reinterpret_cast<SbkObjectType*>(pyobj->ob_type); if (BaseType::hasCast(shiboType)) return reinterpret_cast<T*>(BaseType::cast(shiboType, reinterpret_cast<SbkObject*>(pyobj), SbkType<T>())); return (T*) Wrapper::cppPointer(reinterpret_cast<SbkObject*>(pyobj), SbkType<T>()); |