diff options
Diffstat (limited to 'include/tools/link.hxx')
-rw-r--r-- | include/tools/link.hxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/tools/link.hxx b/include/tools/link.hxx index 9b7e7fe6d302..db8028321594 100644 --- a/include/tools/link.hxx +++ b/include/tools/link.hxx @@ -45,32 +45,32 @@ typedef long (*PSTUB)( void*, void* ); #define IMPL_STUB(Class, Method, ArgType) \ long Class::LinkStub##Method( void* pThis, void* pCaller) \ { \ - return ((Class*)pThis )->Method( (ArgType)pCaller ); \ + return static_cast<Class*>(pThis)->Method( (ArgType)pCaller ); \ } #define IMPL_STATIC_LINK( Class, Method, ArgType, ArgName ) \ long Class::LinkStub##Method( void* pThis, void* pCaller) \ { \ - return Method( (Class*)pThis, (ArgType)pCaller ); \ + return Method( static_cast<Class*>(pThis), (ArgType)pCaller ); \ } \ long Class::Method( Class* pThis, ArgType ArgName ) #define IMPL_STATIC_LINK_NOINSTANCE( Class, Method, ArgType, ArgName ) \ long Class::LinkStub##Method( void* pThis, void* pCaller) \ { \ - return Method( (Class*)pThis, (ArgType)pCaller ); \ + return Method( static_cast<Class*>(pThis), (ArgType)pCaller ); \ } \ long Class::Method( SAL_UNUSED_PARAMETER Class*, ArgType ArgName ) #define IMPL_STATIC_LINK_NOINSTANCE_NOARG( Class, Method ) \ long Class::LinkStub##Method( void* pThis, void* pCaller) \ { \ - return Method( (Class*)pThis, pCaller ); \ + return Method( static_cast<Class*>(pThis), pCaller ); \ } \ long Class::Method( SAL_UNUSED_PARAMETER Class*, SAL_UNUSED_PARAMETER void* ) #define LINK( Inst, Class, Member ) \ - Link( (Class*)Inst, (PSTUB)&Class::LinkStub##Member ) + Link( static_cast<Class*>(Inst), (PSTUB)&Class::LinkStub##Member ) #define STATIC_LINK( Inst, Class, Member ) LINK(Inst, Class, Member) |