diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2019-11-02 19:52:33 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2019-11-02 21:47:38 +0100 |
commit | 7f305223fa6d6a1ad4a6f906b14f879cb01539be (patch) | |
tree | c48f2af6875094ab09853058323c804c6cb36d4c /sc | |
parent | ed94101d8c399f6de2e2b9b7cd31dd6b68d269a8 (diff) |
New loplugin:conditionalstring
Change-Id: I2eab990c15f845b44a3b598571aca361dadf9ff3
Reviewed-on: https://gerrit.libreoffice.org/81946
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/tool/interpr1.cxx | 2 | ||||
-rw-r--r-- | sc/source/filter/excel/xiescher.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/StatisticsDialogs/RegressionDialog.cxx | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/sc/source/core/tool/interpr1.cxx b/sc/source/core/tool/interpr1.cxx index 9b907f429688..151247180655 100644 --- a/sc/source/core/tool/interpr1.cxx +++ b/sc/source/core/tool/interpr1.cxx @@ -8309,7 +8309,7 @@ void ScInterpreter::ScAddressFunc() if (!aDoc.isEmpty()) sTabStr = aDoc + sTabStr; sTabStr += (eConv == FormulaGrammar::CONV_XL_R1C1 || eConv == FormulaGrammar::CONV_XL_A1) ? - OUString("!") : OUString("."); + OUStringLiteral("!") : OUStringLiteral("."); sTabStr += aRefStr; PushString( sTabStr ); } diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx index 6e6567163ab3..fe59a3495ba4 100644 --- a/sc/source/filter/excel/xiescher.cxx +++ b/sc/source/filter/excel/xiescher.cxx @@ -2915,7 +2915,7 @@ OUString XclImpPictureObj::GetOleStorageName() const OUStringBuffer aStrgName; if( (mbEmbedded || mbLinked) && !mbControl && (mnStorageId > 0) ) { - aStrgName = mbEmbedded ? OUString(EXC_STORAGE_OLE_EMBEDDED) : OUString(EXC_STORAGE_OLE_LINKED); + aStrgName = mbEmbedded ? OUStringLiteral(EXC_STORAGE_OLE_EMBEDDED) : OUStringLiteral(EXC_STORAGE_OLE_LINKED); static const sal_Char spcHexChars[] = "0123456789ABCDEF"; for( sal_uInt8 nIndex = 32; nIndex > 0; nIndex -= 4 ) aStrgName.append(OUStringChar( spcHexChars[ ::extract_value< sal_uInt8 >( mnStorageId, nIndex - 4, 4 ) ] )); diff --git a/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx b/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx index ce7208155a76..4441f041e3ef 100644 --- a/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx +++ b/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx @@ -362,7 +362,7 @@ void ScRegressionDialog::WriteRawRegressionResults(AddressWalkerWriter& rOutput, rTemplate.setTemplate(constTemplateLINEST[nRegressionIndex]. replaceFirst("%CALC_INTERCEPT%", - mbCalcIntercept ? OUString("TRUE") : OUString("FALSE"))); + mbCalcIntercept ? OUStringLiteral("TRUE") : OUStringLiteral("FALSE"))); rOutput.writeMatrixFormula(rTemplate.getTemplate(), 1 + mnNumIndependentVars, 5); // Add LINEST result components to template // 1. Add ranges for coefficients and standard errors for indep. vars and the intercept. @@ -408,7 +408,7 @@ void ScRegressionDialog::WriteRegressionStatistics(AddressWalkerWriter& rOutput, "=" + OUString::number(mnNumIndependentVars), "=" + OUString::number(mnNumObservations), "=1 - (1 - %RSQUARED_ADDR%)*(%NUMOBS_ADDR% - 1)/(%NUMOBS_ADDR% - %NUMXVARS_ADDR%" + - (mbCalcIntercept ? OUString(" - 1)") : OUString(")")) + (mbCalcIntercept ? OUStringLiteral(" - 1)") : OUStringLiteral(")")) }; rTemplate.autoReplaceAddress("%NUMXVARS_ADDR%", rOutput.current(1, 2)); |