From d597bb77b271a0e9f2c3f4789517435f6b63f170 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Fri, 12 Jan 2018 20:25:56 +0100 Subject: More loplugin:cstylecast: dbaccess auto-rewrite with "Enable loplugin:cstylecast for some more cases" plus solenv/clang-format/reformat-formatted-files Change-Id: I96df8923f7791288bbd350d75582a9220006ece6 --- dbaccess/source/ui/browser/formadapter.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'dbaccess/source/ui/browser/formadapter.cxx') diff --git a/dbaccess/source/ui/browser/formadapter.cxx b/dbaccess/source/ui/browser/formadapter.cxx index 4660111c2c01..52c2b944659b 100644 --- a/dbaccess/source/ui/browser/formadapter.cxx +++ b/dbaccess/source/ui/browser/formadapter.cxx @@ -1491,14 +1491,14 @@ sal_Bool SAL_CALL SbaXFormAdapter::hasElements() // css::container::XIndexContainer void SAL_CALL SbaXFormAdapter::insertByIndex(sal_Int32 _rIndex, const Any& Element) { - if ( ( _rIndex < 0 ) || ( (size_t)_rIndex >= m_aChildren.size() ) ) + if ( ( _rIndex < 0 ) || ( static_cast(_rIndex) >= m_aChildren.size() ) ) throw css::lang::IndexOutOfBoundsException(); implInsert(Element, _rIndex); } void SAL_CALL SbaXFormAdapter::removeByIndex(sal_Int32 _rIndex) { - if ( ( _rIndex < 0 ) || ( (size_t)_rIndex >= m_aChildren.size() ) ) + if ( ( _rIndex < 0 ) || ( static_cast(_rIndex) >= m_aChildren.size() ) ) throw css::lang::IndexOutOfBoundsException(); Reference< css::form::XFormComponent > xAffected = *(m_aChildren.begin() + _rIndex); @@ -1527,7 +1527,7 @@ void SAL_CALL SbaXFormAdapter::removeByIndex(sal_Int32 _rIndex) // css::container::XIndexReplace void SAL_CALL SbaXFormAdapter::replaceByIndex(sal_Int32 _rIndex, const Any& Element) { - if ( ( _rIndex < 0 ) || ( (size_t)_rIndex >= m_aChildren.size() ) ) + if ( ( _rIndex < 0 ) || ( static_cast(_rIndex) >= m_aChildren.size() ) ) throw css::lang::IndexOutOfBoundsException(); // extract the form component @@ -1594,7 +1594,7 @@ sal_Int32 SAL_CALL SbaXFormAdapter::getCount() Any SAL_CALL SbaXFormAdapter::getByIndex(sal_Int32 _rIndex) { - if ( ( _rIndex < 0 ) || ( (size_t)_rIndex >= m_aChildren.size() ) ) + if ( ( _rIndex < 0 ) || ( static_cast(_rIndex) >= m_aChildren.size() ) ) throw css::lang::IndexOutOfBoundsException(); Reference< css::form::XFormComponent > xElement = *(m_aChildren.begin() + _rIndex); -- cgit