diff options
author | Peter Senna Tschudin <peter.senna@gmail.com> | 2014-05-26 19:41:16 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2014-05-27 01:19:00 -0500 |
commit | 3b24dcc8a8138c1e1495c3dba5ffe5748cb183c2 (patch) | |
tree | 8250ea36b767d906cc6606ab81d198ffda2e8ee1 /sw | |
parent | a1dedadbf0d87a1db24e9b336257678e059882f0 (diff) |
Remove unnecessary semicolons
A simplified version of the semantic match that finds this problem is
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@r1@
statement S;
position p,p1;
@@
S@p1;@p
@script:python r2@
p << r1.p;
p1 << r1.p1;
@@
if p[0].line != p1[0].line_end:
cocci.include_match(False)
@@
position r1.p;
@@
-;@p
// </smpl>
Change-Id: Ib9708d37fbb4c6060f88d5dae3814a2d37b2091e
Reviewed-on: https://gerrit.libreoffice.org/9493
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/docnode/node2lay.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/docnode/nodedump.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/layout/findfrm.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/layout/frmtool.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/layout/wsfrm.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/table/swnewtable.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/table/swtable.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/text/pormulti.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/text/txtfrm.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/uibase/app/swmodul1.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/uibase/uiview/srcview.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/html/swhtml.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxattributeoutput.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtw8nds.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par6.cxx | 2 |
15 files changed, 18 insertions, 18 deletions
diff --git a/sw/source/core/docnode/node2lay.cxx b/sw/source/core/docnode/node2lay.cxx index 201e3bdcc7fb..6a04f88d83f2 100644 --- a/sw/source/core/docnode/node2lay.cxx +++ b/sw/source/core/docnode/node2lay.cxx @@ -330,7 +330,7 @@ SwLayoutFrm* SwNode2LayImpl::UpperFrm( SwFrm* &rpFrm, const SwNode &rNode ) return pUpper; } } - }; + } if( !bMaster ) rpFrm = rpFrm->GetNext(); return pUpper; diff --git a/sw/source/core/docnode/nodedump.cxx b/sw/source/core/docnode/nodedump.cxx index 5de57f28e39c..f0c544797c01 100644 --- a/sw/source/core/docnode/nodedump.cxx +++ b/sw/source/core/docnode/nodedump.cxx @@ -772,7 +772,7 @@ void SwRedlineTbl::dumpAsXml( xmlTextWriterPtr w ) default: sRedlineType = "UNKNOWN"; break; - }; + } writer.writeFormatAttribute( "id", "%s", BAD_CAST(aId.getStr()) ); writer.writeFormatAttribute( "author", "%s", BAD_CAST(aAuthor.getStr()) ); writer.writeFormatAttribute( "date", "%s", BAD_CAST(aDate.getStr()) ); diff --git a/sw/source/core/layout/findfrm.cxx b/sw/source/core/layout/findfrm.cxx index 78c065696e2b..8b4b1e4f6779 100644 --- a/sw/source/core/layout/findfrm.cxx +++ b/sw/source/core/layout/findfrm.cxx @@ -955,7 +955,7 @@ SwCntntFrm* SwFrm::_FindPrevCnt( const bool _bInSameFtn ) { // current content frame is the first content in the // footnote - no previous content exists. - pPrevCntntFrm = 0L;; + pPrevCntntFrm = 0L; } } } diff --git a/sw/source/core/layout/frmtool.cxx b/sw/source/core/layout/frmtool.cxx index 3418f3d9dad6..0f9b78f09809 100644 --- a/sw/source/core/layout/frmtool.cxx +++ b/sw/source/core/layout/frmtool.cxx @@ -426,7 +426,7 @@ static void lcl_InvalidatePosOfLowers( SwLayoutFrm& _rLayoutFrm ) pLowerFrm->InvalidateObjs( true, false ); pLowerFrm = pLowerFrm->GetNext(); - }; + } } SwLayNotify::~SwLayNotify() diff --git a/sw/source/core/layout/wsfrm.cxx b/sw/source/core/layout/wsfrm.cxx index bbab6c3c3e88..7e765e379d0e 100644 --- a/sw/source/core/layout/wsfrm.cxx +++ b/sw/source/core/layout/wsfrm.cxx @@ -666,7 +666,7 @@ void SwFrm::InsertGroupBefore( SwFrm* pParent, SwFrm* pBehind, SwFrm* pSct ) { pLast->mpUpper = pBehind->GetUpper(); pLast = pLast->GetNext(); - }; + } } else { diff --git a/sw/source/core/table/swnewtable.cxx b/sw/source/core/table/swnewtable.cxx index 90110110a00a..4bcf1284b48d 100644 --- a/sw/source/core/table/swnewtable.cxx +++ b/sw/source/core/table/swnewtable.cxx @@ -1078,7 +1078,7 @@ static void lcl_getAllMergedBoxes( const SwTable& rTable, SwSelBoxes& rBoxes, Sw pBox = lcl_LeftBorder2Box( nLeftBorder, rTable.GetTabLines()[nLine] ); if( pBox ) rBoxes.insert( pBox ); - }; + } } /** lcl_UnMerge(..) manipulates the row span attribute of a given master cell diff --git a/sw/source/core/table/swtable.cxx b/sw/source/core/table/swtable.cxx index 5c3d3f620bd9..e3afa6c79c48 100644 --- a/sw/source/core/table/swtable.cxx +++ b/sw/source/core/table/swtable.cxx @@ -1278,7 +1278,7 @@ void SwTable::NewSetTabCols( Parm &rParm, const SwTabCols &rNew, rParm.nOldWish, nOldWidth, true ); lcl_AdjustWidthsInLine( rLines[j], aCopy, rParm, 0 ); bGoOn = !aRowSpanPos.empty() && j > 0; - }; + } aRowSpanPos.clear(); } if( nCurr+1 < (sal_uInt16)rLines.size() ) @@ -1302,7 +1302,7 @@ void SwTable::NewSetTabCols( Parm &rParm, const SwTabCols &rNew, rParm.nOldWish, nOldWidth, false ); lcl_AdjustWidthsInLine( rLines[j], aCopy, rParm, 0 ); bGoOn = !aRowSpanPos.empty() && j+1 < (sal_uInt16)rLines.size(); - }; + } } ::lcl_AdjustWidthsInLine( rLines[nCurr], aOldNew, rParm, COLFUZZY ); } diff --git a/sw/source/core/text/pormulti.cxx b/sw/source/core/text/pormulti.cxx index 9671b54cb1fa..f9ccc77a16ed 100644 --- a/sw/source/core/text/pormulti.cxx +++ b/sw/source/core/text/pormulti.cxx @@ -520,7 +520,7 @@ bool SwDoubleLinePortion::ChgSpaceAdd( SwLineLayout* pCurr, // cancels the manipulation from SwDoubleLinePortion::ChangeSpaceAdd(..) void SwDoubleLinePortion::ResetSpaceAdd( SwLineLayout* pCurr ) { - pCurr->RemoveFirstLLSpaceAdd();; + pCurr->RemoveFirstLLSpaceAdd(); if( !pCurr->GetLLSpaceAddCount() ) pCurr->FinishSpaceAdd(); } diff --git a/sw/source/core/text/txtfrm.cxx b/sw/source/core/text/txtfrm.cxx index ab0d613c7f7d..d1b64864ba77 100644 --- a/sw/source/core/text/txtfrm.cxx +++ b/sw/source/core/text/txtfrm.cxx @@ -1378,7 +1378,7 @@ static bool lcl_ErgoVadis( SwTxtFrm* pFrm, sal_Int32 &rPos, const PrepareHint eP if( ePrep == PREP_ERGOSUM ) { if( rFtnInfo.aErgoSum.isEmpty() ) - return false;; + return false; rPos = pFrm->GetOfst(); } else diff --git a/sw/source/core/uibase/app/swmodul1.cxx b/sw/source/core/uibase/app/swmodul1.cxx index 4c3733a15966..dcdfc0101625 100644 --- a/sw/source/core/uibase/app/swmodul1.cxx +++ b/sw/source/core/uibase/app/swmodul1.cxx @@ -421,7 +421,7 @@ OUString SwModule::GetRedlineAuthor(sal_uInt16 nPos) while(!(nPos < pAuthorNames->size())) { InsertRedlineAuthor("nn"); - }; + } return (*pAuthorNames)[nPos]; } diff --git a/sw/source/core/uibase/uiview/srcview.cxx b/sw/source/core/uibase/uiview/srcview.cxx index b939c79f934c..c97da041ef3e 100644 --- a/sw/source/core/uibase/uiview/srcview.cxx +++ b/sw/source/core/uibase/uiview/srcview.cxx @@ -485,7 +485,7 @@ void SwSrcView::GetState(SfxItemSet& rSet) { if(!GetSearchItem()) rSet.DisableItem(nWhich); - }; + } break; case SID_UNDO: case SID_REDO: diff --git a/sw/source/filter/html/swhtml.cxx b/sw/source/filter/html/swhtml.cxx index 6ea4a0fd9be3..c0e10c17a790 100644 --- a/sw/source/filter/html/swhtml.cxx +++ b/sw/source/filter/html/swhtml.cxx @@ -2593,7 +2593,7 @@ SwViewShell *SwHTMLParser::CallEndAction( bool bChkAction, bool bChkPtr ) const bool bOldLock = pActionViewShell->IsViewLocked(); pActionViewShell->LockView( true ); const bool bOldEndActionByVirDev = pActionViewShell->IsEndActionByVirDev(); - pActionViewShell->SetEndActionByVirDev( true );; + pActionViewShell->SetEndActionByVirDev( true ); ((SwEditShell*)pActionViewShell)->EndAction(); pActionViewShell->SetEndActionByVirDev( bOldEndActionByVirDev ); pActionViewShell->LockView( bOldLock ); diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx index 2e2cb9d6c612..7fc9acb4bb88 100644 --- a/sw/source/filter/ww8/docxattributeoutput.cxx +++ b/sw/source/filter/ww8/docxattributeoutput.cxx @@ -3089,7 +3089,7 @@ void DocxAttributeOutput::TableRowRedline( ww8::WW8TableNodeInfoInner::Pointer_t FSEND ); } break; - }; + } } } } @@ -3135,7 +3135,7 @@ void DocxAttributeOutput::TableCellRedline( ww8::WW8TableNodeInfoInner::Pointer_ FSEND ); } break; - }; + } } } } diff --git a/sw/source/filter/ww8/wrtw8nds.cxx b/sw/source/filter/ww8/wrtw8nds.cxx index e17625969a2e..55c3fa2aab63 100644 --- a/sw/source/filter/ww8/wrtw8nds.cxx +++ b/sw/source/filter/ww8/wrtw8nds.cxx @@ -1321,7 +1321,7 @@ const SwRedlineData* SwWW8AttrIter::GetRunLevelRedline( sal_Int32 nPos ) break; default: break; - }; + } pCurRedline = 0; ++nCurRedlinePos; } @@ -1357,7 +1357,7 @@ const SwRedlineData* SwWW8AttrIter::GetRunLevelRedline( sal_Int32 nPos ) break; default: break; - }; + } } break; } diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx index 1ab57d53d25e..c55fd660debf 100644 --- a/sw/source/filter/ww8/ww8par6.cxx +++ b/sw/source/filter/ww8/ww8par6.cxx @@ -4178,7 +4178,7 @@ void SwWW8ImplReader::Read_UL( sal_uInt16 nId, const sal_uInt8* pData, short nLe break; default: return; - }; + } NewAttr( aUL ); } |