diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-05-29 12:04:32 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-05-29 12:04:32 +0200 |
commit | 3a05a08ba79a99b5c070d14eceefe7b0b6ca03c6 (patch) | |
tree | 4acee06b8ba02bb23df44ad1eb98a757212d0027 /forms | |
parent | f9a8dd3bbb6b60b8f25ae4108868dc778cd51dfb (diff) |
loplugin:redundantcast: const_cast to same type
Change-Id: I5fe081bc2edfe14c81372ae0fd407e493d80d689
Diffstat (limited to 'forms')
-rw-r--r-- | forms/source/component/DatabaseForm.cxx | 2 | ||||
-rw-r--r-- | forms/source/component/FormComponent.cxx | 4 | ||||
-rw-r--r-- | forms/source/runtime/formoperations.cxx | 2 | ||||
-rw-r--r-- | forms/source/xforms/datatypes_impl.hxx | 4 |
4 files changed, 6 insertions, 6 deletions
diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx index 2e325405c20e..da50462c3df8 100644 --- a/forms/source/component/DatabaseForm.cxx +++ b/forms/source/component/DatabaseForm.cxx @@ -4052,7 +4052,7 @@ OUString SAL_CALL ODatabaseForm::getName() throw( RuntimeException, std::excepti { throw WrappedTargetRuntimeException( "ODatabaseForm::getName", - *const_cast< ODatabaseForm* >( this ), + *this, ::cppu::getCaughtException() ); } diff --git a/forms/source/component/FormComponent.cxx b/forms/source/component/FormComponent.cxx index 0e3a00b7ef49..61b7542a69e3 100644 --- a/forms/source/component/FormComponent.cxx +++ b/forms/source/component/FormComponent.cxx @@ -646,7 +646,7 @@ OUString SAL_CALL OControlModel::getName() throw(RuntimeException, std::exceptio css::uno::Any a(cppu::getCaughtException()); throw WrappedTargetRuntimeException( "OControlModel::getName", - *const_cast< OControlModel* >( this ), + *this, a ); } @@ -664,7 +664,7 @@ void SAL_CALL OControlModel::setName(const OUString& _rName) throw(RuntimeExcept css::uno::Any a(cppu::getCaughtException()); throw WrappedTargetRuntimeException( "OControlModel::setName", - *const_cast< OControlModel* >( this ), + *this, a ); } diff --git a/forms/source/runtime/formoperations.cxx b/forms/source/runtime/formoperations.cxx index 2ccb2df5005f..b770a5f0e129 100644 --- a/forms/source/runtime/formoperations.cxx +++ b/forms/source/runtime/formoperations.cxx @@ -803,7 +803,7 @@ namespace frm catch( const SQLException& ) { throw; } catch( const Exception& ) { - throw WrappedTargetException( OUString(), *const_cast< FormOperations* >( this ), ::cppu::getCaughtException() ); + throw WrappedTargetException( OUString(), *this, ::cppu::getCaughtException() ); } impl_invalidateAllSupportedFeatures_nothrow( aGuard ); diff --git a/forms/source/xforms/datatypes_impl.hxx b/forms/source/xforms/datatypes_impl.hxx index 8f1a54f44c9f..4bd194c0a7d5 100644 --- a/forms/source/xforms/datatypes_impl.hxx +++ b/forms/source/xforms/datatypes_impl.hxx @@ -51,8 +51,8 @@ template< typename CONCRETE_DATA_TYPE_IMPL, typename SUPERCLASS > { if ( !m_bPropertiesRegistered ) { - const_cast< ODerivedDataType* >( this )->registerProperties(); - const_cast< ODerivedDataType* >( this )->m_bPropertiesRegistered = true; + this->registerProperties(); + m_bPropertiesRegistered = true; } return *ODerivedDataType< CONCRETE_DATA_TYPE_IMPL, SUPERCLASS >::getArrayHelper(); |