summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2021-06-08 15:21:44 +0200
committerMiklos Vajna <vmiklos@collabora.com>2021-06-09 09:13:06 +0200
commitdfafa053945aa9ffea347c4b9a98f255b15016bf (patch)
tree4a5889580141701b008214df0af231498fb58cda
parent6cd8dd2123354578a1499a1e85e268f702f38954 (diff)
-Werror,-Wunused-but-set-variable (Clang 13 trunk)
The only read of nChgFormatLevel (spelled "nChgFmtLevel" back then) back at 84a3db80b4fd66c6854b3135b5f69b61fd828e62 "initial import" was in a > #ifndef NUM_RELSPACE block that was removed with f917bb6900bad2c9382374a2cbc5678b278dde2e "INTEGRATION: CWS swnumtree". It apparently was dead code, as sw/inc/sw.mk had included > CDEFS+=-DNUM_RELSPACE ever since at least 7b0b5cdfeed656b279bc32cd929630d5fc25878b "initial import" (which was later removed with 58003f28fc09cb2021e145afa0d0d692a7a402a7 "INTEGRATION: CWS writercorehandoff" when all its remaining uses were also removed in that CWS writercorehandoff). Change-Id: I5972e2c949d21970e7f3f98a0a61600265ccb66b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116844 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
-rw-r--r--sw/source/core/doc/docnum.cxx10
1 files changed, 0 insertions, 10 deletions
diff --git a/sw/source/core/doc/docnum.cxx b/sw/source/core/doc/docnum.cxx
index 2420532c5bee..586324391888 100644
--- a/sw/source/core/doc/docnum.cxx
+++ b/sw/source/core/doc/docnum.cxx
@@ -1185,16 +1185,6 @@ bool SwDoc::ReplaceNumRule( const SwPosition& rPos,
if ( !aTextNodeList.empty() )
{
SwRegHistory aRegH( pUndo ? pUndo->GetHistory() : nullptr );
- sal_uInt16 nChgFormatLevel = 0;
- for( sal_uInt8 n = 0; n < MAXLEVEL; ++n )
- {
- const SwNumFormat& rOldFormat = pOldRule->Get( n ),
- & rNewFormat = pNewRule->Get( n );
-
- if( rOldFormat.GetAbsLSpace() != rNewFormat.GetAbsLSpace() ||
- rOldFormat.GetFirstLineOffset() != rNewFormat.GetFirstLineOffset() )
- nChgFormatLevel |= ( 1 << n );
- }
const SwTextNode* pGivenTextNode = rPos.nNode.GetNode().GetTextNode();
SwNumRuleItem aRule( rNewRule );