diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2014-05-23 22:11:27 +0200 |
---|---|---|
committer | Julien Nabet <serval2412@yahoo.fr> | 2014-05-23 22:11:52 +0200 |
commit | ac76cc7e605b1bc9c0ff8e24d0b9995a8247074e (patch) | |
tree | 797df8cc9387fa70a0c09e574f49714ce4dc6710 /stoc/source/invocation_adapterfactory/iafactory.cxx | |
parent | 3191d7d1302dbde2445b9f300b3eb853120ede65 (diff) |
Prefer cppu::UnoType<T>::get() to ::getCppuType((T*)0) part20
Change-Id: If87cdfb2c605254f6d69baa4ca5aec09091caa68
Diffstat (limited to 'stoc/source/invocation_adapterfactory/iafactory.cxx')
-rw-r--r-- | stoc/source/invocation_adapterfactory/iafactory.cxx | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/stoc/source/invocation_adapterfactory/iafactory.cxx b/stoc/source/invocation_adapterfactory/iafactory.cxx index 216ee96b8562..3c0951f0af21 100644 --- a/stoc/source/invocation_adapterfactory/iafactory.cxx +++ b/stoc/source/invocation_adapterfactory/iafactory.cxx @@ -276,9 +276,7 @@ bool AdapterImpl::coerce_assign( { OSL_ASSERT( p_exc->pType->eTypeClass == typelib_TypeClass_EXCEPTION ); - if (typelib_typedescriptionreference_isAssignableFrom( - ::getCppuType( - (RuntimeException const *) 0 ).getTypeLibType(), + if (typelib_typedescriptionreference_isAssignableFrom( cppu::UnoType<RuntimeException>::get() ).getTypeLibType(), p_exc->pType )) { // is RuntimeException or derived: rethrow @@ -731,8 +729,7 @@ FactoryImpl::FactoryImpl( Reference< XComponentContext > const & xContext ) rShortSeqType.getDescription( &m_pShortSeqTD ); // script.XInvocation typelib_TypeDescription * pTD = 0; - const Type & rInvType = ::getCppuType( - (const Reference< script::XInvocation > *)0 ); + const Type & rInvType = cppu::UnoType<script::XInvocation>::get(); TYPELIB_DANGER_GET( &pTD, rInvType.getTypeLibType() ); typelib_InterfaceTypeDescription * pITD; pITD = reinterpret_cast<typelib_InterfaceTypeDescription*>(pTD); @@ -746,7 +743,7 @@ FactoryImpl::FactoryImpl( Reference< XComponentContext > const & xContext ) &m_pGetValueTD, pITD->ppMembers[ 3 ] ); // getValue() // script.XTypeConverter const Type & rTCType = - ::getCppuType( (const Reference< script::XTypeConverter > *)0 ); + cppu::UnoType<script::XTypeConverter>::get(); TYPELIB_DANGER_GET( &pTD, rTCType.getTypeLibType() ); pITD = reinterpret_cast<typelib_InterfaceTypeDescription*>(pTD); ::typelib_typedescriptionreference_getDescription( |