diff options
author | Noel Grandin <noel@peralex.com> | 2016-02-02 16:15:51 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-02-08 06:08:14 +0000 |
commit | b14224fe97b8a44232c9c1401d3a49771f46582e (patch) | |
tree | 8f9cf31cf4b51a0edbb43022499a6acd17d0945d /sw/source/core/bastyp/index.cxx | |
parent | c474e610e453d0f38f7cc6cb9559ad7e7b5d69ca (diff) |
loplugin:unusedmethods
using an idea from dtardon:
<dtardon> noelgrandin, hi. could you try to run the unusedmethods clang
plugin with "make build-nocheck"? that would catch functions that are
only used in tests. e.g., i just removed the whole o3tl::range class,
which has not been used in many years, but htere was a test for it...
<noelgrandin> dtardon, interesting idea! Sure, I can do that.
Change-Id: I5653953a426a2186a1e43017212d87ffce520387
Reviewed-on: https://gerrit.libreoffice.org/22041
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sw/source/core/bastyp/index.cxx')
-rw-r--r-- | sw/source/core/bastyp/index.cxx | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/sw/source/core/bastyp/index.cxx b/sw/source/core/bastyp/index.cxx index dac9ba9c2769..cd8dd4afc0a9 100644 --- a/sw/source/core/bastyp/index.cxx +++ b/sw/source/core/bastyp/index.cxx @@ -296,16 +296,6 @@ void SwIndexReg::MoveTo( SwIndexReg& rArr ) // SwIndex -sal_Int32 SwIndex::operator++(int) -{ - SAL_WARN_IF( !(m_nIndex < SAL_MAX_INT32), "sw.core", - "SwIndex::operator++(int) wraps around" ); - - const sal_Int32 nOldIndex = m_nIndex; - ChgValue( *this, m_nIndex+1 ); - return nOldIndex; -} - sal_Int32 SwIndex::operator++() { SAL_WARN_IF( !(m_nIndex < SAL_MAX_INT32), "sw.core", @@ -346,20 +336,6 @@ sal_Int32 SwIndex::operator-=( sal_Int32 const nVal ) return ChgValue( *this, m_nIndex - nVal ).m_nIndex; } -sal_Int32 SwIndex::operator+=( const SwIndex & rIndex ) -{ - SAL_WARN_IF( !(m_nIndex <= SAL_MAX_INT32 - rIndex.m_nIndex), "sw.core", - "SwIndex::operator+=(SwIndex) wraps around" ); - return ChgValue( *this, m_nIndex + rIndex.m_nIndex ).m_nIndex; -} - -sal_Int32 SwIndex::operator-=( const SwIndex & rIndex ) -{ - SAL_WARN_IF( !(m_nIndex >= rIndex.m_nIndex), "sw.core", - "SwIndex::operator-=(SwIndex) wraps around" ); - return ChgValue( *this, m_nIndex - rIndex.m_nIndex ).m_nIndex; -} - bool SwIndex::operator< ( const SwIndex & rIndex ) const { // Attempt to compare indices into different arrays |