summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2016-05-10 16:42:16 +0200
committerAshod Nakashian <ashod.nakashian@collabora.co.uk>2016-07-20 01:26:06 -0400
commite7b11300cd813f821d1ec5cb4633ce2c5f7d1b9f (patch)
treea6c39d9d4cde1baa84a9d788affbce3508af89a8 /sc
parent34f591ca95c4c63be092da4c4b2294230404f336 (diff)
Replace fallthrough comments with new SAL_FALLTHROUGH macro
...which (in LIBO_INTERNAL_ONLY) for Clang expands to [[clang::fallthrough]] in preparation of enabling -Wimplicit-fallthrough. (This is only relevant for C++11, as neither C nor old C++ has a way to annotate intended fallthroughs.) Could use BOOST_FALLTHROUGH instead of introducing our own SAL_FALLTHROUGH, but that would require adding back in dependencies on boost_headers to many libraries where we carefully removed any remaining Boost dependencies only recently. (At least make SAL_FALLTHROUGH strictly LIBO_INTERNAL_ONLY, so its future evolution will not have any impact on the stable URE interface.) C++17 will have a proper [[fallthroug]], eventually removing the need for a macro altogether. (cherry picked from commit 14cd5182c5f64c43581c82db8c958369152226ac) Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/attrib.cxx4
-rw-r--r--sc/source/core/data/conditio.cxx2
-rw-r--r--sc/source/core/tool/compiler.cxx8
-rw-r--r--sc/source/core/tool/interpr1.cxx6
-rw-r--r--sc/source/core/tool/scmatrix.cxx2
-rw-r--r--sc/source/core/tool/token.cxx15
-rw-r--r--sc/source/filter/dif/difimp.cxx12
-rw-r--r--sc/source/filter/excel/excform.cxx10
-rw-r--r--sc/source/filter/excel/read.cxx2
-rw-r--r--sc/source/filter/excel/xeformula.cxx2
-rw-r--r--sc/source/filter/excel/xestyle.cxx12
-rw-r--r--sc/source/filter/excel/xetable.cxx2
-rw-r--r--sc/source/filter/excel/xiescher.cxx3
-rw-r--r--sc/source/filter/excel/xihelper.cxx4
-rw-r--r--sc/source/filter/html/htmlexp.cxx2
-rw-r--r--sc/source/filter/html/htmlpars.cxx3
-rw-r--r--sc/source/ui/dbgui/validate.cxx3
-rw-r--r--sc/source/ui/docshell/docfunc.cxx8
-rw-r--r--sc/source/ui/docshell/docsh.cxx6
-rw-r--r--sc/source/ui/unoobj/tokenuno.cxx2
-rw-r--r--sc/source/ui/view/cellsh3.cxx2
-rw-r--r--sc/source/ui/view/formatsh.cxx2
22 files changed, 62 insertions, 50 deletions
diff --git a/sc/source/core/data/attrib.cxx b/sc/source/core/data/attrib.cxx
index 9072410caece..d12240484e35 100644
--- a/sc/source/core/data/attrib.cxx
+++ b/sc/source/core/data/attrib.cxx
@@ -407,7 +407,7 @@ bool ScRangeItem::GetPresentation
{
case SFX_ITEM_PRESENTATION_COMPLETE:
rText = ScGlobal::GetRscString(STR_AREA) + ": ";
- /* !!! fall-through !!! */
+ SAL_FALLTHROUGH;
case SFX_ITEM_PRESENTATION_NAMELESS:
{
@@ -854,7 +854,7 @@ bool ScViewObjectModeItem::GetPresentation
ePres = SFX_ITEM_PRESENTATION_NAMELESS; // Default setting!
break;
}
- /* !!! fall-through !!! */
+ SAL_FALLTHROUGH;
case SFX_ITEM_PRESENTATION_NAMELESS:
rText += ScGlobal::GetRscString(STR_VOBJ_MODE_SHOW+GetValue());
return true;
diff --git a/sc/source/core/data/conditio.cxx b/sc/source/core/data/conditio.cxx
index aaeb3c880d1a..c4b32cd813dd 100644
--- a/sc/source/core/data/conditio.cxx
+++ b/sc/source/core/data/conditio.cxx
@@ -93,8 +93,8 @@ static bool lcl_HasRelRef( ScDocument* pDoc, ScTokenArray* pFormula, sal_uInt16
ScSingleRefData& rRef2 = t->GetDoubleRef()->Ref2;
if ( rRef2.IsColRel() || rRef2.IsRowRel() || rRef2.IsTabRel() )
return true;
+ SAL_FALLTHROUGH;
}
- // fall through
case svSingleRef:
{
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 6c44e6b0f0eb..417ca2623a36 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -2350,7 +2350,7 @@ Label_MaskStateMachine:
SetError( errStringOverflow);
eState = ssSkipReference;
}
- // fall through and follow logic
+ SAL_FALLTHROUGH;
case ssSkipReference:
// ODF reference: ['External'#$'Sheet'.A1:.B2] with dots being
// mandatory also if no sheet name. 'External'# is optional,
@@ -2475,7 +2475,7 @@ Label_MaskStateMachine:
case SC_COMPILER_FILE_TAB_SEP:
// sheet name should follow
nRefInName |= kFileSep;
- // fallthru
+ SAL_FALLTHROUGH;
default:
// quote not followed by quote => close
nRefInName |= kClose;
@@ -3048,7 +3048,7 @@ bool ScCompiler::IsReference( const OUString& rName )
// operator as it is within a quoted name.
if (rName[0] != '\'')
return false; // Document name has to be single quoted.
- // fallthru
+ SAL_FALLTHROUGH;
case FormulaGrammar::CONV_XL_R1C1:
// C2 or C[1] are valid entire column references.
if (IsDoubleReference( rName))
@@ -5221,7 +5221,7 @@ bool ScCompiler::HandleTableRef()
if (pDBData->HasHeader())
aRange.aStart.IncRow();
}
- // fallthru
+ SAL_FALLTHROUGH;
case ScTableRefToken::HEADERS_DATA:
{
if (pDBData->HasTotals())
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx
index 2c303f94a978..4a27ab6cb63c 100644
--- a/sc/source/core/tool/interpr1.cxx
+++ b/sc/source/core/tool/interpr1.cxx
@@ -2631,7 +2631,7 @@ void ScInterpreter::ScFormula()
PushMatrix( pResMat);
return;
}
- // fallthru
+ SAL_FALLTHROUGH;
case svSingleRef :
{
ScAddress aAdr;
@@ -3133,7 +3133,7 @@ void ScInterpreter::ScValue()
{
case SC_MATVAL_EMPTY:
fVal = 0.0;
- // fallthru
+ SAL_FALLTHROUGH;
case SC_MATVAL_VALUE:
case SC_MATVAL_BOOLEAN:
PushDouble( fVal);
@@ -5939,7 +5939,7 @@ void ScInterpreter::ScLookup()
break;
case svDoubleRef:
aResAdr.Set( nResCol1, nResRow1, nResTab);
- // fallthru
+ SAL_FALLTHROUGH;
case svSingleRef:
PushCellResultToken( true, aResAdr, nullptr, nullptr);
break;
diff --git a/sc/source/core/tool/scmatrix.cxx b/sc/source/core/tool/scmatrix.cxx
index 61df4dd119e6..e5de4b3692d4 100644
--- a/sc/source/core/tool/scmatrix.cxx
+++ b/sc/source/core/tool/scmatrix.cxx
@@ -571,7 +571,7 @@ svl::SharedString ScMatrixImpl::GetString(SCSIZE nC, SCSIZE nR) const
case mdds::mtm::element_numeric:
case mdds::mtm::element_boolean:
fErr = maMat.get_numeric(aPos);
- //fallthrough
+ SAL_FALLTHROUGH;
default:
OSL_FAIL("ScMatrixImpl::GetString: access error, no string");
}
diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index 1fe40aaea6a6..f516a765e5e7 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -1136,7 +1136,7 @@ void ScMatrixFormulaCellToken::SetUpperLeftDouble( double f )
xUpperLeft = new FormulaDoubleToken( f);
break;
}
- // fall through
+ SAL_FALLTHROUGH;
default:
{
OSL_FAIL("ScMatrixFormulaCellToken::SetUpperLeftDouble: not modifying unhandled token type");
@@ -1914,7 +1914,7 @@ FormulaToken* ScTokenArray::MergeArray( )
case ocArrayOpen :
nStart = i; // stop iteration
- // fall through to ArrayRowSep
+ SAL_FALLTHROUGH; // to ArrayRowSep
case ocArrayRowSep :
if( checkArraySep( bPrevWasSep, true ) )
@@ -2278,7 +2278,7 @@ void ScTokenArray::ReadjustRelative3DReferences( const ScAddress& rOldPos,
rRef2.SetAddress(aAbs, rNewPos);
}
}
- // fall through
+ SAL_FALLTHROUGH;
case svSingleRef :
{
ScSingleRefData& rRef1 = *p->GetSingleRef();
@@ -2295,7 +2295,7 @@ void ScTokenArray::ReadjustRelative3DReferences( const ScAddress& rOldPos,
ScAddress aAbs = rRef2.toAbs(rOldPos);
rRef2.SetAddress(aAbs, rNewPos);
}
- // fall through
+ SAL_FALLTHROUGH;
case svExternalSingleRef :
{
ScSingleRefData& rRef1 = *p->GetSingleRef();
@@ -2345,7 +2345,8 @@ bool SkipReference(formula::FormulaToken* pToken, const ScAddress& rPos, const S
ScSingleRefData& rRef = *pToken->GetSingleRef2();
if (rRef.IsColRel() || rRef.IsRowRel())
return true;
- } // fall through
+ }
+ SAL_FALLTHROUGH;
case svSingleRef:
{
ScSingleRefData& rRef = *pToken->GetSingleRef();
@@ -4109,7 +4110,7 @@ void ScTokenArray::AdjustReferenceOnMovedOriginIfOtherSheet( const ScAddress& rO
{
case svExternalSingleRef:
bAdjust = true; // always
- // fallthru
+ SAL_FALLTHROUGH;
case svSingleRef:
{
ScSingleRefData& rRef = *p->GetSingleRef();
@@ -4122,7 +4123,7 @@ void ScTokenArray::AdjustReferenceOnMovedOriginIfOtherSheet( const ScAddress& rO
break;
case svExternalDoubleRef:
bAdjust = true; // always
- // fallthru
+ SAL_FALLTHROUGH;
case svDoubleRef:
{
ScComplexRefData& rRef = *p->GetDoubleRef();
diff --git a/sc/source/filter/dif/difimp.cxx b/sc/source/filter/dif/difimp.cxx
index 1dd10d6fc16c..46487a3f99c4 100644
--- a/sc/source/filter/dif/difimp.cxx
+++ b/sc/source/filter/dif/difimp.cxx
@@ -382,7 +382,7 @@ TOPIC DifParser::GetNextTopic()
case S_UNKNOWN:
// skip 2 lines
ReadNextLine( aLine );
- // fall-through
+ SAL_FALLTHROUGH;
case S_ERROR_L2: // error happened in line 2
// skip 1 line
ReadNextLine( aLine );
@@ -700,8 +700,9 @@ bool DifParser::ScanFloatVal( const sal_Unicode* pStart )
eS = S_EXP;
break;
case 0x00: // IsNumberEnding( cAkt )
- bRet = true; // no
- default: // break!
+ bRet = true;
+ SAL_FALLTHROUGH;
+ default:
eS = S_END;
}
}
@@ -721,8 +722,9 @@ bool DifParser::ScanFloatVal( const sal_Unicode* pStart )
eS = S_EXP_FIRST;
break;
case 0x00: // IsNumberEnding( cAkt )
- bRet = true; // no
- default: // break!
+ bRet = true;
+ SAL_FALLTHROUGH;
+ default:
eS = S_END;
}
}
diff --git a/sc/source/filter/excel/excform.cxx b/sc/source/filter/excel/excform.cxx
index 47d7a85204a4..c05f8adf3bec 100644
--- a/sc/source/filter/excel/excform.cxx
+++ b/sc/source/filter/excel/excform.cxx
@@ -414,7 +414,7 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s
case EXC_BIFF4: aIn.Ignore( 10 ); break;
case EXC_BIFF5:
SAL_INFO( "sc", "-ExcelToSc::Convert(): 0x1A does not exist in Biff5!" );
- //fall-through
+ SAL_FALLTHROUGH;
default:
SAL_INFO( "sc", "-ExcelToSc::Convert(): A little oblivious?" );
}
@@ -427,7 +427,7 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s
case EXC_BIFF4: aIn.Ignore( 4 ); break;
case EXC_BIFF5:
SAL_INFO( "sc", "-ExcelToSc::Convert(): 0x1B does not exist in Biff5!" );
- //fall-through
+ SAL_FALLTHROUGH;
default:
SAL_INFO( "sc", "-ExcelToSc::Convert(): A little oblivious?" );
}
@@ -625,7 +625,7 @@ ConvErr ExcelToSc::Convert( const ScTokenArray*& pErgebnis, XclImpStream& aIn, s
case 0x66:
case 0x26: // Constant Reference Subexpression [321 271]
aExtensions.push_back( EXTENSION_MEMAREA );
- // fall through
+ SAL_FALLTHROUGH;
case 0x47:
case 0x67:
@@ -1028,7 +1028,7 @@ ConvErr ExcelToSc::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sal
case EXC_BIFF3:
case EXC_BIFF4: nIgnore = 10; break;
case EXC_BIFF5: SAL_INFO( "sc", "-ExcelToSc::Convert(): 0x1A does not exist in Biff5!" );
- //fall-through
+ SAL_FALLTHROUGH;
default: SAL_INFO( "sc", "-ExcelToSc::Convert(): A little oblivious?" );
}
break;
@@ -1039,7 +1039,7 @@ ConvErr ExcelToSc::Convert( _ScRangeListTabs& rRangeList, XclImpStream& aIn, sal
case EXC_BIFF3:
case EXC_BIFF4: nIgnore = 4; break;
case EXC_BIFF5: SAL_INFO( "sc", "-ExcelToSc::Convert(): 0x1B does not exist in Biff5!" );
- //fall-through
+ SAL_FALLTHROUGH;
default: SAL_INFO( "sc", "-ExcelToSc::Convert(): A little oblivious?" );
}
break;
diff --git a/sc/source/filter/excel/read.cxx b/sc/source/filter/excel/read.cxx
index 93ed6df0a48d..29188b3fa6ba 100644
--- a/sc/source/filter/excel/read.cxx
+++ b/sc/source/filter/excel/read.cxx
@@ -904,7 +904,7 @@ FltError ImportExcel8::Read()
break;
case Biff8W: // workbook
OSL_FAIL( "ImportExcel8::Read - double workbook globals" );
- // run through
+ SAL_FALLTHROUGH;
case Biff8V: // VB module
default:
// TODO: do not create a sheet in the Calc document
diff --git a/sc/source/filter/excel/xeformula.cxx b/sc/source/filter/excel/xeformula.cxx
index 7ef64cc074bf..74bb0cd8d1b8 100644
--- a/sc/source/filter/excel/xeformula.cxx
+++ b/sc/source/filter/excel/xeformula.cxx
@@ -1742,7 +1742,7 @@ void XclExpFmlaCompImpl::AppendTrailingParam( XclExpFuncData& rFuncData )
PrepareParam( rFuncData );
AppendIntToken( 0 );
FinishParam( rFuncData );
- // do not break, add next default parameter
+ SAL_FALLTHROUGH; // add next default parameter
case 2:
PrepareParam( rFuncData );
AppendIntToken( 1 );
diff --git a/sc/source/filter/excel/xestyle.cxx b/sc/source/filter/excel/xestyle.cxx
index 8e67c026e4c1..39697ac68910 100644
--- a/sc/source/filter/excel/xestyle.cxx
+++ b/sc/source/filter/excel/xestyle.cxx
@@ -1478,8 +1478,6 @@ bool XclExpCellAlign::FillFromItemSet(
switch( eBiff )
{
- // ALL 'case's - run through!
-
case EXC_BIFF8: // attributes new in BIFF8
{
// text indent
@@ -1495,6 +1493,8 @@ bool XclExpCellAlign::FillFromItemSet(
// CTL text direction
SetScFrameDir( GETITEMVALUE( rItemSet, SvxFrameDirectionItem, ATTR_WRITINGDIR, SvxFrameDirection ) );
bUsed |= ScfTools::CheckItem( rItemSet, ATTR_WRITINGDIR, bStyle );
+
+ SAL_FALLTHROUGH;
}
case EXC_BIFF5: // attributes new in BIFF5
@@ -1519,6 +1519,8 @@ bool XclExpCellAlign::FillFromItemSet(
bUsed |= ScfTools::CheckItem( rItemSet, ATTR_ROTATE_VALUE, bStyle );
}
mnOrient = XclTools::GetXclOrientFromRot( mnRotation );
+
+ SAL_FALLTHROUGH;
}
case EXC_BIFF3: // attributes new in BIFF3
@@ -1526,6 +1528,8 @@ bool XclExpCellAlign::FillFromItemSet(
// text wrap
mbLineBreak = bForceLineBreak || GETITEMBOOL( rItemSet, ATTR_LINEBREAK );
bUsed |= bForceLineBreak || ScfTools::CheckItem( rItemSet, ATTR_LINEBREAK, bStyle );
+
+ SAL_FALLTHROUGH;
}
case EXC_BIFF2: // attributes new in BIFF2
@@ -1711,8 +1715,6 @@ bool XclExpCellBorder::FillFromItemSet(
switch( eBiff )
{
- // ALL 'case's - run through!
-
case EXC_BIFF8: // attributes new in BIFF8
{
const SvxLineItem& rTLBRItem = GETITEM( rItemSet, SvxLineItem, ATTR_BORDER_TLBR );
@@ -1740,6 +1742,8 @@ bool XclExpCellBorder::FillFromItemSet(
bUsed |= ScfTools::CheckItem( rItemSet, ATTR_BORDER_TLBR, bStyle ) ||
ScfTools::CheckItem( rItemSet, ATTR_BORDER_BLTR, bStyle );
+
+ SAL_FALLTHROUGH;
}
case EXC_BIFF5:
diff --git a/sc/source/filter/excel/xetable.cxx b/sc/source/filter/excel/xetable.cxx
index b05b3d31234b..1dc6dbbf4d75 100644
--- a/sc/source/filter/excel/xetable.cxx
+++ b/sc/source/filter/excel/xetable.cxx
@@ -2505,7 +2505,7 @@ XclExpCellTable::XclExpCellTable( const XclExpRoot& rRoot ) :
default:
OSL_FAIL( "XclExpCellTable::XclExpCellTable - unknown cell type" );
- // run-through!
+ SAL_FALLTHROUGH;
case CELLTYPE_NONE:
{
xCell.reset( new XclExpBlankCell(
diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx
index a1eb0433d214..ca306b57c4f1 100644
--- a/sc/source/filter/excel/xiescher.cxx
+++ b/sc/source/filter/excel/xiescher.cxx
@@ -1540,9 +1540,10 @@ void XclImpTextObj::DoPreProcessSdrObj( XclImpDffConverter& rDffConv, SdrObject&
}
break;
- case EXC_OBJ_ORIENT_STACKED: // PASSTHROUGH INTENDED
+ case EXC_OBJ_ORIENT_STACKED:
{
// sj: STACKED is not supported, maybe it can be optimized here a bit
+ SAL_FALLTHROUGH;
}
case EXC_OBJ_ORIENT_90CW:
{
diff --git a/sc/source/filter/excel/xihelper.cxx b/sc/source/filter/excel/xihelper.cxx
index 6b1bc9497ddc..dc243fdd9095 100644
--- a/sc/source/filter/excel/xihelper.cxx
+++ b/sc/source/filter/excel/xihelper.cxx
@@ -405,7 +405,7 @@ void XclImpHFConverter::ParseString( const OUString& rHFString )
{
case '\"':
--pChar;
- // run through
+ SAL_FALLTHROUGH;
case ',':
eState = xlPSFontStyle;
break;
@@ -688,7 +688,7 @@ void XclImpUrlHelper::DecodeUrl(
lclAppendUrlChar( rUrl, cCurrDrive );
rUrl += ":";
}
- // run through
+ SAL_FALLTHROUGH;
case EXC_URL_SUBDIR:
if( bEncoded )
rUrl += "\\";
diff --git a/sc/source/filter/html/htmlexp.cxx b/sc/source/filter/html/htmlexp.cxx
index 12ce2a120229..60e802655669 100644
--- a/sc/source/filter/html/htmlexp.cxx
+++ b/sc/source/filter/html/htmlexp.cxx
@@ -1181,7 +1181,7 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab )
bFieldText = WriteFieldText(aCell.mpEditText);
if ( bFieldText )
break;
- //! else: fallthru
+ SAL_FALLTHROUGH;
default:
ScCellFormat::GetString(aCell, nFormat, aStrOut, &pColor, *pFormatter, pDoc);
}
diff --git a/sc/source/filter/html/htmlpars.cxx b/sc/source/filter/html/htmlpars.cxx
index 5ecfeaa71f0c..ba3e01a1531d 100644
--- a/sc/source/filter/html/htmlpars.cxx
+++ b/sc/source/filter/html/htmlpars.cxx
@@ -1594,7 +1594,8 @@ void ScHTMLLayoutParser::ProcToken( ImportInfo* pInfo )
// Do not set bInCell to true, TableDataOn does that
pActEntry->aItemSet.Put(
SvxWeightItem( WEIGHT_BOLD, ATTR_FONT_WEIGHT) );
- } // fall through
+ SAL_FALLTHROUGH;
+ }
case HTML_TABLEDATA_ON: // Opens cell
{
TableDataOn( pInfo );
diff --git a/sc/source/ui/dbgui/validate.cxx b/sc/source/ui/dbgui/validate.cxx
index db7301280b1e..55ec8396252f 100644
--- a/sc/source/ui/dbgui/validate.cxx
+++ b/sc/source/ui/dbgui/validate.cxx
@@ -635,7 +635,8 @@ IMPL_LINK_NOARG_TYPED(ScTPValidationValue, SelectHdl, ListBox&, void)
case SC_VALIDDLG_DATA_EQLESS: m_pFtMin->SetText( maStrMax ); break;
case SC_VALIDDLG_DATA_VALIDRANGE:
- case SC_VALIDDLG_DATA_INVALIDRANGE: bShowMax = true; // fall through
+ case SC_VALIDDLG_DATA_INVALIDRANGE: bShowMax = true;
+ SAL_FALLTHROUGH;
case SC_VALIDDLG_DATA_GREATER:
case SC_VALIDDLG_DATA_EQGREATER: m_pFtMin->SetText( maStrMin ); break;
diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx
index 10faf54726c4..dad4824f1a1c 100644
--- a/sc/source/ui/docshell/docfunc.cxx
+++ b/sc/source/ui/docshell/docfunc.cxx
@@ -1472,7 +1472,7 @@ bool canInsertCellsByPivot(const ScRange& rRange, const ScMarkData& rMarkData, I
{
aRange.aStart.SetCol(0);
aRange.aEnd.SetCol(MAXCOL);
- // Continue below.
+ SAL_FALLTHROUGH;
}
case INS_CELLSDOWN:
{
@@ -1508,7 +1508,7 @@ bool canInsertCellsByPivot(const ScRange& rRange, const ScMarkData& rMarkData, I
{
aRange.aStart.SetRow(0);
aRange.aEnd.SetRow(MAXROW);
- // Continue below.
+ SAL_FALLTHROUGH;
}
case INS_CELLSRIGHT:
{
@@ -1570,7 +1570,7 @@ bool canDeleteCellsByPivot(const ScRange& rRange, const ScMarkData& rMarkData, D
{
aRange.aStart.SetCol(0);
aRange.aEnd.SetCol(MAXCOL);
- // Continue below.
+ SAL_FALLTHROUGH;
}
case DEL_CELLSUP:
{
@@ -1595,7 +1595,7 @@ bool canDeleteCellsByPivot(const ScRange& rRange, const ScMarkData& rMarkData, D
{
aRange.aStart.SetRow(0);
aRange.aEnd.SetRow(MAXROW);
- // Continue below.
+ SAL_FALLTHROUGH;
}
case DEL_CELLSLEFT:
{
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index e018bef6b81a..f7d98a6be422 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -938,7 +938,8 @@ void ScDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
SetError( ERRCODE_IO_ABORT, OSL_LOG_PREFIX ); // this error code will produce no error message, but will break the further saving process
}
}
- } // fall through
+ SAL_FALLTHROUGH;
+ }
case SFX_EVENT_SAVETODOC:
// #i108978# If no event is sent before saving, there will also be no "...DONE" event,
// and SAVE/SAVEAS can't be distinguished from SAVETO. So stream copying is only enabled
@@ -951,7 +952,8 @@ void ScDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
{
// new positions are used after "save" and "save as", but not "save to"
UseSheetSaveEntries(); // use positions from saved file for next saving
- } // fall through
+ SAL_FALLTHROUGH;
+ }
case SFX_EVENT_SAVETODOCDONE:
// only reset the flag, don't use the new positions
if (pSheetSaveData)
diff --git a/sc/source/ui/unoobj/tokenuno.cxx b/sc/source/ui/unoobj/tokenuno.cxx
index 6e769d03bd61..03bf7faf8fec 100644
--- a/sc/source/ui/unoobj/tokenuno.cxx
+++ b/sc/source/ui/unoobj/tokenuno.cxx
@@ -478,7 +478,7 @@ bool ScTokenConversion::ConvertToTokenSequence( const ScDocument& rDoc,
break;
default:
OSL_TRACE( "ScTokenConversion::ConvertToTokenSequence: unhandled token type SvStackVar %d", rToken.GetType());
- //fall-through
+ SAL_FALLTHROUGH;
case svSep: // occurs with ocSep, ocOpen, ocClose, ocArray*
case svJump: // occurs with ocIf, ocChoose
case svMissing: // occurs with ocMissing
diff --git a/sc/source/ui/view/cellsh3.cxx b/sc/source/ui/view/cellsh3.cxx
index 132fe9373ba0..b287493af17f 100644
--- a/sc/source/ui/view/cellsh3.cxx
+++ b/sc/source/ui/view/cellsh3.cxx
@@ -80,7 +80,7 @@ void ScCellShell::Execute( SfxRequest& rReq )
//! cannot always be switched ????
if (!pTabViewShell->GetViewFrame()->GetFrame().IsInPlace())
pTabViewShell->SetDontSwitch(true); // do not switch off EditShell
- // no break
+ SAL_FALLTHROUGH;
case FID_CELL_FORMAT:
case SID_ENABLE_HYPHENATION:
diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx
index e0de249a8248..bc8f446f75bb 100644
--- a/sc/source/ui/view/formatsh.cxx
+++ b/sc/source/ui/view/formatsh.cxx
@@ -420,8 +420,8 @@ void ScFormatShell::ExecuteStyle( SfxRequest& rReq )
{
}
}
+ SAL_FALLTHROUGH;
}
- //fall-through
case SID_STYLE_EDIT:
case SID_STYLE_DELETE:
case SID_STYLE_HIDE: