summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--accessibility/source/extended/textwindowaccessibility.cxx2
-rw-r--r--basic/source/sbx/sbxcurr.cxx2
-rw-r--r--chart2/source/tools/DataSeriesHelper.cxx2
-rw-r--r--compilerplugins/clang/passstuffbyref.cxx21
-rw-r--r--connectivity/source/inc/file/fcode.hxx2
-rw-r--r--dbaccess/source/ui/uno/copytablewizard.cxx2
-rw-r--r--editeng/qa/items/borderline_test.cxx4
-rw-r--r--editeng/source/accessibility/AccessibleEditableTextPara.cxx2
-rw-r--r--include/connectivity/FValue.hxx20
-rw-r--r--include/dbaccess/genericcontroller.hxx2
-rw-r--r--include/sfx2/templatedlg.hxx2
-rw-r--r--include/xmloff/nmspmap.hxx2
-rw-r--r--lotuswordpro/source/filter/lwplayout.cxx4
-rw-r--r--lotuswordpro/source/filter/lwplayout.hxx12
-rw-r--r--oox/source/drawingml/table/tableproperties.cxx2
-rw-r--r--opencl/inc/opencl_device_selection.h4
-rw-r--r--opencl/source/opencl_device.cxx4
-rw-r--r--sax/qa/cppunit/xmlimport.cxx2
-rw-r--r--sax/source/fastparser/fastparser.cxx2
-rw-r--r--sc/inc/dptabres.hxx2
-rw-r--r--sc/source/core/data/bcaslot.cxx2
-rw-r--r--sc/source/ui/namedlg/namemgrtable.cxx2
-rw-r--r--sc/source/ui/unoobj/funcuno.cxx4
-rw-r--r--sc/source/ui/vba/vbarange.cxx4
-rw-r--r--sdext/source/minimizer/informationdialog.cxx2
-rw-r--r--sdext/source/minimizer/optimizerdialogcontrols.cxx2
-rw-r--r--sfx2/source/bastyp/fltfnc.cxx2
-rw-r--r--sfx2/source/doc/templatedlg.cxx8
-rw-r--r--svtools/source/filter/exportdialog.cxx2
-rw-r--r--sw/inc/fmtclds.hxx2
-rw-r--r--sw/source/core/access/accpara.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par.hxx2
-rw-r--r--sw/source/uibase/dbui/dbmgr.cxx2
-rw-r--r--uui/source/iahndl-ssl.cxx2
-rw-r--r--vcl/unx/generic/gdi/xrender_peer.hxx2
35 files changed, 71 insertions, 64 deletions
diff --git a/accessibility/source/extended/textwindowaccessibility.cxx b/accessibility/source/extended/textwindowaccessibility.cxx
index 61175803e86b..5ddf1cacfcc2 100644
--- a/accessibility/source/extended/textwindowaccessibility.cxx
+++ b/accessibility/source/extended/textwindowaccessibility.cxx
@@ -979,7 +979,7 @@ struct IndexCompare
: pValues(pVals)
{
}
- bool operator() ( const sal_Int32& a, const sal_Int32& b ) const
+ bool operator() ( sal_Int32 a, sal_Int32 b ) const
{
return pValues[a].Name < pValues[b].Name;
}
diff --git a/basic/source/sbx/sbxcurr.cxx b/basic/source/sbx/sbxcurr.cxx
index 6070a19ade8d..2f7f05aa7448 100644
--- a/basic/source/sbx/sbxcurr.cxx
+++ b/basic/source/sbx/sbxcurr.cxx
@@ -26,7 +26,7 @@
#include "sbxconv.hxx"
-static OUString ImpCurrencyToString( const sal_Int64 &rVal )
+static OUString ImpCurrencyToString( sal_Int64 rVal )
{
bool isNeg = ( rVal < 0 );
sal_Int64 absVal = isNeg ? -rVal : rVal;
diff --git a/chart2/source/tools/DataSeriesHelper.cxx b/chart2/source/tools/DataSeriesHelper.cxx
index e668ccbf4565..b3fda1c72937 100644
--- a/chart2/source/tools/DataSeriesHelper.cxx
+++ b/chart2/source/tools/DataSeriesHelper.cxx
@@ -725,7 +725,7 @@ bool hasUnhiddenData( const uno::Reference< chart2::XDataSeries >& xSeries )
struct lcl_LessIndex
{
- inline bool operator() ( const sal_Int32& first, const sal_Int32& second ) const
+ inline bool operator() ( sal_Int32 first, sal_Int32 second ) const
{
return ( first < second );
}
diff --git a/compilerplugins/clang/passstuffbyref.cxx b/compilerplugins/clang/passstuffbyref.cxx
index a14d01f6a5a4..ca2283cbb5e0 100644
--- a/compilerplugins/clang/passstuffbyref.cxx
+++ b/compilerplugins/clang/passstuffbyref.cxx
@@ -58,8 +58,11 @@ bool PassStuffByRef::VisitFunctionDecl(const FunctionDecl * functionDecl) {
if (ignoreLocation(functionDecl)) {
return true;
}
- if (functionDecl->isDeleted())
+ if (functionDecl->isDeleted()
+ || functionDecl->isFunctionTemplateSpecialization())
+ {
return true;
+ }
// only consider base declarations, not overriden ones, or we warn on methods that
// are overriding stuff from external libraries
const CXXMethodDecl * methodDecl = dyn_cast<CXXMethodDecl>(functionDecl);
@@ -73,9 +76,8 @@ bool PassStuffByRef::VisitFunctionDecl(const FunctionDecl * functionDecl) {
}
void PassStuffByRef::checkParams(const FunctionDecl * functionDecl) {
- // only warn on the definition/prototype of the function,
- // not on the function implementation
- if (functionDecl->isThisDeclarationADefinition()) {
+ // Only warn on the definition of the function:
+ if (!functionDecl->isThisDeclarationADefinition()) {
return;
}
unsigned n = functionDecl->getNumParams();
@@ -109,6 +111,13 @@ void PassStuffByRef::checkParams(const FunctionDecl * functionDecl) {
("passing primitive type param %0 by const &, rather pass by value"),
pvDecl->getLocation())
<< t << pvDecl->getSourceRange();
+ auto can = functionDecl->getCanonicalDecl();
+ if (can->getLocation() != functionDecl->getLocation()) {
+ report(
+ DiagnosticsEngine::Note, "function is declared here:",
+ can->getLocation())
+ << can->getSourceRange();
+ }
}
}
}
@@ -223,10 +232,10 @@ bool PassStuffByRef::isPrimitiveConstRef(QualType type) {
if (type->isIncompleteType()) {
return false;
}
- if (!type->isReferenceType()) {
+ const clang::ReferenceType* referenceType = type->getAs<ReferenceType>();
+ if (referenceType == nullptr) {
return false;
}
- const clang::ReferenceType* referenceType = dyn_cast<ReferenceType>(type);
QualType pointeeQT = referenceType->getPointeeType();
if (!pointeeQT.isConstQualified()) {
return false;
diff --git a/connectivity/source/inc/file/fcode.hxx b/connectivity/source/inc/file/fcode.hxx
index 8d5fa24c46ce..9d8082a188bb 100644
--- a/connectivity/source/inc/file/fcode.hxx
+++ b/connectivity/source/inc/file/fcode.hxx
@@ -65,7 +65,7 @@ namespace connectivity
protected:
sal_Int32 m_eDBType;
- OOperand(const sal_Int32& _rType) : m_eDBType(_rType){}
+ OOperand(sal_Int32 _rType) : m_eDBType(_rType){}
OOperand() : m_eDBType(css::sdbc::DataType::OTHER){}
public:
diff --git a/dbaccess/source/ui/uno/copytablewizard.cxx b/dbaccess/source/ui/uno/copytablewizard.cxx
index 08f714a5b1a4..4e6143130b09 100644
--- a/dbaccess/source/ui/uno/copytablewizard.cxx
+++ b/dbaccess/source/ui/uno/copytablewizard.cxx
@@ -966,7 +966,7 @@ namespace
class ValueTransfer
{
public:
- ValueTransfer( const sal_Int32& _rSourcePos, const sal_Int32& _rDestPos, const ::std::vector< sal_Int32 >& _rColTypes,
+ ValueTransfer( sal_Int32 _rSourcePos, sal_Int32 _rDestPos, const ::std::vector< sal_Int32 >& _rColTypes,
const Reference< XRow >& _rxSource, const Reference< XParameters >& _rxDest )
:m_rSourcePos( _rSourcePos )
,m_rDestPos( _rDestPos )
diff --git a/editeng/qa/items/borderline_test.cxx b/editeng/qa/items/borderline_test.cxx
index b97a41432978..58a46ffc8b01 100644
--- a/editeng/qa/items/borderline_test.cxx
+++ b/editeng/qa/items/borderline_test.cxx
@@ -32,12 +32,12 @@ CPPUNIT_NS_BEGIN
template<> struct assertion_traits<SvxBorderStyle>
{
- static bool equal( const SvxBorderStyle& x, const SvxBorderStyle& y )
+ static bool equal( SvxBorderStyle x, SvxBorderStyle y )
{
return x == y;
}
- static std::string toString( const SvxBorderStyle& x )
+ static std::string toString( SvxBorderStyle x )
{
OStringStream ost;
ost << static_cast<unsigned int>(x);
diff --git a/editeng/source/accessibility/AccessibleEditableTextPara.cxx b/editeng/source/accessibility/AccessibleEditableTextPara.cxx
index f17996fd4230..56669b5e67ce 100644
--- a/editeng/source/accessibility/AccessibleEditableTextPara.cxx
+++ b/editeng/source/accessibility/AccessibleEditableTextPara.cxx
@@ -880,7 +880,7 @@ namespace accessibility
{
const PropertyValue* pValues;
explicit IndexCompare( const PropertyValue* pVals ) : pValues(pVals) {}
- bool operator() ( const sal_Int32& a, const sal_Int32& b ) const
+ bool operator() ( sal_Int32 a, sal_Int32 b ) const
{
return pValues[a].Name < pValues[b].Name;
}
diff --git a/include/connectivity/FValue.hxx b/include/connectivity/FValue.hxx
index 21933c7100b5..55341f828e92 100644
--- a/include/connectivity/FValue.hxx
+++ b/include/connectivity/FValue.hxx
@@ -120,7 +120,7 @@ namespace connectivity
operator=(_rRH);
}
- ORowSetValue(const float& _rRH)
+ ORowSetValue(float _rRH)
:m_eTypeKind(css::sdbc::DataType::FLOAT)
,m_bNull(true)
,m_bBound(true)
@@ -131,7 +131,7 @@ namespace connectivity
operator=(_rRH);
}
- ORowSetValue(const sal_Int8& _rRH)
+ ORowSetValue(sal_Int8 _rRH)
:m_eTypeKind(css::sdbc::DataType::TINYINT)
,m_bNull(true)
,m_bBound(true)
@@ -142,7 +142,7 @@ namespace connectivity
operator=(_rRH);
}
- ORowSetValue(const sal_uInt8& _rRH)
+ ORowSetValue(sal_uInt8 _rRH)
:m_eTypeKind(css::sdbc::DataType::TINYINT)
,m_bNull(true)
,m_bBound(true)
@@ -152,7 +152,7 @@ namespace connectivity
m_aValue.m_pString = nullptr;
operator=(_rRH);
}
- ORowSetValue(const sal_Int16& _rRH)
+ ORowSetValue(sal_Int16 _rRH)
:m_eTypeKind(css::sdbc::DataType::SMALLINT)
,m_bNull(true)
,m_bBound(true)
@@ -162,7 +162,7 @@ namespace connectivity
m_aValue.m_pString = nullptr;
operator=(_rRH);
}
- ORowSetValue(const sal_uInt16& _rRH)
+ ORowSetValue(sal_uInt16 _rRH)
:m_eTypeKind(css::sdbc::DataType::SMALLINT)
,m_bNull(true)
,m_bBound(true)
@@ -172,7 +172,7 @@ namespace connectivity
m_aValue.m_pString = nullptr;
operator=(_rRH);
}
- ORowSetValue(const sal_Int32& _rRH)
+ ORowSetValue(sal_Int32 _rRH)
:m_eTypeKind(css::sdbc::DataType::INTEGER)
,m_bNull(true)
,m_bBound(true)
@@ -182,7 +182,7 @@ namespace connectivity
m_aValue.m_pString = nullptr;
operator=(_rRH);
}
- ORowSetValue(const sal_uInt32& _rRH)
+ ORowSetValue(sal_uInt32 _rRH)
:m_eTypeKind(css::sdbc::DataType::INTEGER)
,m_bNull(true)
,m_bBound(true)
@@ -192,7 +192,7 @@ namespace connectivity
m_aValue.m_pString = nullptr;
operator=(_rRH);
}
- ORowSetValue(const sal_Int64& _rRH)
+ ORowSetValue(sal_Int64 _rRH)
:m_eTypeKind(css::sdbc::DataType::BIGINT)
,m_bNull(true)
,m_bBound(true)
@@ -202,7 +202,7 @@ namespace connectivity
m_aValue.m_pString = nullptr;
operator=(_rRH);
}
- ORowSetValue(const sal_uInt64& _rRH)
+ ORowSetValue(sal_uInt64 _rRH)
:m_eTypeKind(css::sdbc::DataType::BIGINT)
,m_bNull(true)
,m_bBound(true)
@@ -213,7 +213,7 @@ namespace connectivity
operator=(_rRH);
}
- ORowSetValue(const bool& _rRH)
+ ORowSetValue(bool _rRH)
:m_eTypeKind(css::sdbc::DataType::BIT)
,m_bNull(true)
,m_bBound(true)
diff --git a/include/dbaccess/genericcontroller.hxx b/include/dbaccess/genericcontroller.hxx
index 5e9b792275f2..dae637c6bf0d 100644
--- a/include/dbaccess/genericcontroller.hxx
+++ b/include/dbaccess/genericcontroller.hxx
@@ -156,7 +156,7 @@ namespace dbaui
struct CompareFeatureById : ::std::binary_function< SupportedFeatures::value_type, sal_Int32, bool >
{
- inline bool operator()( const SupportedFeatures::value_type& _aType, const sal_Int32& _nId ) const
+ inline bool operator()( const SupportedFeatures::value_type& _aType, sal_Int32 _nId ) const
{
return !!( _nId == _aType.second.nFeatureId );
}
diff --git a/include/sfx2/templatedlg.hxx b/include/sfx2/templatedlg.hxx
index 3affc1b79b93..26e6959db8d6 100644
--- a/include/sfx2/templatedlg.hxx
+++ b/include/sfx2/templatedlg.hxx
@@ -194,7 +194,7 @@ public:
return msSelectedCategory;
};
- inline void SetSelectLabelText(OUString sText) const {
+ inline void SetSelectLabelText(OUString const & sText) const {
mpSelectLabel->SetText(sText);
};
diff --git a/include/xmloff/nmspmap.hxx b/include/xmloff/nmspmap.hxx
index 82e1b8627b96..5f2bac1de514 100644
--- a/include/xmloff/nmspmap.hxx
+++ b/include/xmloff/nmspmap.hxx
@@ -52,7 +52,7 @@ public:
struct uInt32lt
{
- bool operator()( const sal_uInt32 &r1, const sal_uInt32 &r2) const
+ bool operator()( sal_uInt32 r1, sal_uInt32 r2) const
{
return r1 < r2;
}
diff --git a/lotuswordpro/source/filter/lwplayout.cxx b/lotuswordpro/source/filter/lwplayout.cxx
index 23e1a19890e4..3845024bf401 100644
--- a/lotuswordpro/source/filter/lwplayout.cxx
+++ b/lotuswordpro/source/filter/lwplayout.cxx
@@ -711,7 +711,7 @@ bool LwpMiddleLayout::MarginsSameAsParent()
* @descr: Get margin
* @param: nWhichSide - 0: left, 1: right, 2:top, 3: bottom
*/
-double LwpMiddleLayout::MarginsValue(const sal_uInt8 &nWhichSide)
+double LwpMiddleLayout::MarginsValue(sal_uInt8 nWhichSide)
{
double fValue = 0;
if((nWhichSide==MARGIN_LEFT)||(nWhichSide==MARGIN_RIGHT))
@@ -751,7 +751,7 @@ double LwpMiddleLayout::MarginsValue(const sal_uInt8 &nWhichSide)
* @param:
* @return:
*/
-double LwpMiddleLayout::ExtMarginsValue(const sal_uInt8 &nWhichSide)
+double LwpMiddleLayout::ExtMarginsValue(sal_uInt8 nWhichSide)
{
double fValue = 0;
if(m_nOverrideFlag & OVER_MARGINS)
diff --git a/lotuswordpro/source/filter/lwplayout.hxx b/lotuswordpro/source/filter/lwplayout.hxx
index a4b211711154..3dd9a0fbe725 100644
--- a/lotuswordpro/source/filter/lwplayout.hxx
+++ b/lotuswordpro/source/filter/lwplayout.hxx
@@ -144,7 +144,7 @@ public:
m_bGettingHasProtection = false;
return bRet;
}
- double GetMarginsValue(const sal_uInt8& nWhichSide)
+ double GetMarginsValue(sal_uInt8 nWhichSide)
{
if (m_bGettingMarginsValue)
throw std::runtime_error("recursion in layout");
@@ -153,7 +153,7 @@ public:
m_bGettingMarginsValue = false;
return fRet;
}
- double GetExtMarginsValue(const sal_uInt8& nWhichSide)
+ double GetExtMarginsValue(sal_uInt8 nWhichSide)
{
if (m_bGettingExtMarginsValue)
throw std::runtime_error("recursion in layout");
@@ -214,8 +214,8 @@ protected:
bool HasProtection();
virtual bool HonorProtection();
virtual bool IsProtected();
- virtual double MarginsValue(const sal_uInt8& /*nWhichSide*/){return 0;}
- virtual double ExtMarginsValue(const sal_uInt8& /*nWhichSide*/){return 0;}
+ virtual double MarginsValue(sal_uInt8 /*nWhichSide*/){return 0;}
+ virtual double ExtMarginsValue(sal_uInt8 /*nWhichSide*/){return 0;}
virtual bool MarginsSameAsParent();
protected:
bool m_bGettingHonorProtection;
@@ -387,8 +387,8 @@ public:
protected:
void Read() override;
virtual bool MarginsSameAsParent() override;
- virtual double MarginsValue(const sal_uInt8& nWhichSide) override;
- virtual double ExtMarginsValue(const sal_uInt8& nWhichSide) override;
+ virtual double MarginsValue(sal_uInt8 nWhichSide) override;
+ virtual double ExtMarginsValue(sal_uInt8 nWhichSide) override;
private:
LwpObjectID m_BasedOnStyle;
LwpLayoutGeometry* Geometry();
diff --git a/oox/source/drawingml/table/tableproperties.cxx b/oox/source/drawingml/table/tableproperties.cxx
index 4112ce8568be..053572a7bc08 100644
--- a/oox/source/drawingml/table/tableproperties.cxx
+++ b/oox/source/drawingml/table/tableproperties.cxx
@@ -99,7 +99,7 @@ namespace
}
//for pptx just has table style id
-static void SetTableStyleProperties(TableStyle* &pTableStyle , const sal_Int32& tblFillClr,const sal_Int32& tblTextClr, const sal_Int32& lineBdrClr)
+static void SetTableStyleProperties(TableStyle* &pTableStyle , sal_Int32 tblFillClr, sal_Int32 tblTextClr, sal_Int32 lineBdrClr)
{
//whole table fill style and color
oox::drawingml::FillPropertiesPtr pWholeTabFillProperties( new oox::drawingml::FillProperties );
diff --git a/opencl/inc/opencl_device_selection.h b/opencl/inc/opencl_device_selection.h
index d49974cf848a..45e9f5b397d3 100644
--- a/opencl/inc/opencl_device_selection.h
+++ b/opencl/inc/opencl_device_selection.h
@@ -81,7 +81,7 @@ struct ds_profile
std::vector<ds_device> devices;
OString version;
- ds_profile(OString& inVersion)
+ ds_profile(OString const & inVersion)
: version(inVersion)
{}
};
@@ -125,7 +125,7 @@ inline bool getDeviceInfoBool(cl_device_id aDeviceId, cl_device_info aDeviceInfo
return bCLBool == CL_TRUE;
}
-inline ds_status initDSProfile(std::unique_ptr<ds_profile>& rProfile, OString rVersion)
+inline ds_status initDSProfile(std::unique_ptr<ds_profile>& rProfile, OString const & rVersion)
{
int numDevices;
cl_uint numPlatforms;
diff --git a/opencl/source/opencl_device.cxx b/opencl/source/opencl_device.cxx
index a653ac71016c..0a0d28ee4200 100644
--- a/opencl/source/opencl_device.cxx
+++ b/opencl/source/opencl_device.cxx
@@ -465,7 +465,7 @@ class LogWriter
private:
SvFileStream maStream;
public:
- explicit LogWriter(OUString aFileName)
+ explicit LogWriter(OUString const & aFileName)
: maStream(aFileName, StreamMode::WRITE)
{}
@@ -495,7 +495,7 @@ public:
};
-void writeDevicesLog(std::unique_ptr<ds_profile>& rProfile, OUString sProfilePath, int nSelectedIndex)
+void writeDevicesLog(std::unique_ptr<ds_profile>& rProfile, OUString const & sProfilePath, int nSelectedIndex)
{
OUString aCacheFile(sProfilePath + "opencl_devices.log");
LogWriter aWriter(aCacheFile);
diff --git a/sax/qa/cppunit/xmlimport.cxx b/sax/qa/cppunit/xmlimport.cxx
index ab8a7593bd34..28c2764489e8 100644
--- a/sax/qa/cppunit/xmlimport.cxx
+++ b/sax/qa/cppunit/xmlimport.cxx
@@ -44,7 +44,7 @@ using namespace css::io;
using namespace std;
Reference< XInputStream > createStreamFromFile (
- const OUString filePath)
+ const OUString & filePath)
{
Reference< XInputStream > xInputStream;
OUString aInStr;
diff --git a/sax/source/fastparser/fastparser.cxx b/sax/source/fastparser/fastparser.cxx
index 88a193eb3732..fe69161888bf 100644
--- a/sax/source/fastparser/fastparser.cxx
+++ b/sax/source/fastparser/fastparser.cxx
@@ -89,7 +89,7 @@ struct NameWithToken
OUString msName;
sal_Int32 mnToken;
- NameWithToken(const OUString& sName, const sal_Int32& nToken) :
+ NameWithToken(const OUString& sName, sal_Int32 nToken) :
msName(sName), mnToken(nToken) {}
};
diff --git a/sc/inc/dptabres.hxx b/sc/inc/dptabres.hxx
index 827171d32eda..4528c406d0da 100644
--- a/sc/inc/dptabres.hxx
+++ b/sc/inc/dptabres.hxx
@@ -220,7 +220,7 @@ class ScDPDataMember;
struct MemberHashIndexFunc : public std::unary_function< const SCROW &, size_t >
{
- size_t operator() (const SCROW &rDataIndex) const { return rDataIndex; }
+ size_t operator() (SCROW rDataIndex) const { return rDataIndex; }
};
struct ScDPParentDimData
diff --git a/sc/source/core/data/bcaslot.cxx b/sc/source/core/data/bcaslot.cxx
index 8d5e1bb24623..4a7548886b53 100644
--- a/sc/source/core/data/bcaslot.cxx
+++ b/sc/source/core/data/bcaslot.cxx
@@ -709,7 +709,7 @@ void ScBroadcastAreaSlotMachine::ComputeAreaPoints( const ScRange& rRange,
}
inline void ComputeNextSlot( SCSIZE & nOff, SCSIZE & nBreak, ScBroadcastAreaSlot** & pp,
- SCSIZE & nStart, ScBroadcastAreaSlot** const & ppSlots, SCSIZE const & nRowBreak )
+ SCSIZE & nStart, ScBroadcastAreaSlot** const & ppSlots, SCSIZE nRowBreak )
{
if ( nOff < nBreak )
{
diff --git a/sc/source/ui/namedlg/namemgrtable.cxx b/sc/source/ui/namedlg/namemgrtable.cxx
index eedf33cca60d..c15a2b7da6e2 100644
--- a/sc/source/ui/namedlg/namemgrtable.cxx
+++ b/sc/source/ui/namedlg/namemgrtable.cxx
@@ -238,7 +238,7 @@ void ScRangeManagerTable::SetEntry(const ScRangeNameLine& rLine)
namespace {
//ensure that the minimum column size is respected
-void CalculateItemSize(const long& rTableSize, long& rItemNameSize, long& rItemRangeSize)
+void CalculateItemSize(long rTableSize, long& rItemNameSize, long& rItemRangeSize)
{
long aItemScopeSize = rTableSize - rItemNameSize - rItemRangeSize;
diff --git a/sc/source/ui/unoobj/funcuno.cxx b/sc/source/ui/unoobj/funcuno.cxx
index c5cb6d2a4791..24af4217a7ef 100644
--- a/sc/source/ui/unoobj/funcuno.cxx
+++ b/sc/source/ui/unoobj/funcuno.cxx
@@ -348,11 +348,11 @@ public:
// the other types methods are here just to reflect the orig code and for
// completeness.
- void visitElem( long nCol, long nRow, const sal_Int16& elem )
+ void visitElem( long nCol, long nRow, sal_Int16 elem )
{
mpDoc->SetValue( (SCCOL) nCol, (SCROW) nRow, 0, elem );
}
- void visitElem( long nCol, long nRow, const sal_Int32& elem )
+ void visitElem( long nCol, long nRow, sal_Int32 elem )
{
mpDoc->SetValue( (SCCOL) nCol, (SCROW) nRow, 0, elem );
}
diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx
index 95f1d2b4d0b4..c7ad99222ee2 100644
--- a/sc/source/ui/vba/vbarange.cxx
+++ b/sc/source/ui/vba/vbarange.cxx
@@ -2254,7 +2254,7 @@ ScVbaRange::Select() throw (uno::RuntimeException, std::exception)
}
}
-bool cellInRange( const table::CellRangeAddress& rAddr, const sal_Int32& nCol, const sal_Int32& nRow )
+bool cellInRange( const table::CellRangeAddress& rAddr, sal_Int32 nCol, sal_Int32 nRow )
{
if ( nCol >= rAddr.StartColumn && nCol <= rAddr.EndColumn &&
nRow >= rAddr.StartRow && nRow <= rAddr.EndRow )
@@ -2262,7 +2262,7 @@ bool cellInRange( const table::CellRangeAddress& rAddr, const sal_Int32& nCol, c
return false;
}
-void setCursor( const SCCOL& nCol, const SCROW& nRow, const uno::Reference< frame::XModel >& xModel, bool bInSel = true )
+void setCursor( SCCOL nCol, SCROW nRow, const uno::Reference< frame::XModel >& xModel, bool bInSel = true )
{
ScTabViewShell* pShell = excel::getBestViewShell( xModel );
if ( pShell )
diff --git a/sdext/source/minimizer/informationdialog.cxx b/sdext/source/minimizer/informationdialog.cxx
index 07c6fde501e9..c7f6c860c7d2 100644
--- a/sdext/source/minimizer/informationdialog.cxx
+++ b/sdext/source/minimizer/informationdialog.cxx
@@ -189,7 +189,7 @@ OUString InsertButton( InformationDialog& rInformationDialog, const OUString& rC
}
-static OUString ImpValueOfInMB( const sal_Int64& rVal )
+static OUString ImpValueOfInMB( sal_Int64 rVal )
{
double fVal( static_cast<double>( rVal ) );
fVal /= ( 1 << 20 );
diff --git a/sdext/source/minimizer/optimizerdialogcontrols.cxx b/sdext/source/minimizer/optimizerdialogcontrols.cxx
index 65a86fed806d..486cad585ffb 100644
--- a/sdext/source/minimizer/optimizerdialogcontrols.cxx
+++ b/sdext/source/minimizer/optimizerdialogcontrols.cxx
@@ -567,7 +567,7 @@ void OptimizerDialog::InitPage3()
}
-static OUString ImpValueOfInMB( const sal_Int64& rVal, sal_Unicode nSeparator = '.' )
+static OUString ImpValueOfInMB( sal_Int64 rVal, sal_Unicode nSeparator = '.' )
{
double fVal( static_cast<double>( rVal ) );
fVal /= ( 1 << 20 );
diff --git a/sfx2/source/bastyp/fltfnc.cxx b/sfx2/source/bastyp/fltfnc.cxx
index f382ff321e40..d820d49bb092 100644
--- a/sfx2/source/bastyp/fltfnc.cxx
+++ b/sfx2/source/bastyp/fltfnc.cxx
@@ -874,7 +874,7 @@ std::shared_ptr<const SfxFilter> SfxFilterMatcherIter::Next()
using given separator
---------------------------------------------------------------*/
OUString implc_convertStringlistToString( const uno::Sequence< OUString >& lList ,
- const sal_Unicode& cSeparator,
+ sal_Unicode cSeparator,
const OUString& sPrefix )
{
OUStringBuffer sString ( 1000 ) ;
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 41224d5a1bf0..41a87402527f 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -101,7 +101,7 @@ class SearchView_Keyword
public:
SearchView_Keyword (const OUString &rKeyword, FILTER_APPLICATION App)
- : maKeyword(rKeyword), meApp(App)
+ : maKeyword(rKeyword.toAsciiLowerCase()), meApp(App)
{}
bool operator() (const TemplateItemProperties &rItem)
@@ -131,13 +131,11 @@ public:
return bRet && MatchSubstring(rItem.aName);
}
- bool MatchSubstring( OUString sItemName )
+ bool MatchSubstring( OUString const & sItemName )
{
if(maKeyword.isEmpty())
return false;
- sItemName = sItemName.toAsciiLowerCase();
- maKeyword = maKeyword.toAsciiLowerCase();
- if(sItemName.indexOf(maKeyword) >= 0)
+ if(sItemName.toAsciiLowerCase().indexOf(maKeyword) >= 0)
return true;
return false;
}
diff --git a/svtools/source/filter/exportdialog.cxx b/svtools/source/filter/exportdialog.cxx
index 6473791af0d6..dd9799ca39e6 100644
--- a/svtools/source/filter/exportdialog.cxx
+++ b/svtools/source/filter/exportdialog.cxx
@@ -821,7 +821,7 @@ void ExportDialog::setupControls()
mpInfo->Show();
}
-static OUString ImpValueOfInKB( const sal_Int64& rVal )
+static OUString ImpValueOfInKB( sal_Int64 rVal )
{
double fVal( static_cast<double>( rVal ) );
fVal /= ( 1 << 10 );
diff --git a/sw/inc/fmtclds.hxx b/sw/inc/fmtclds.hxx
index 9938f765231f..89327b553d67 100644
--- a/sw/inc/fmtclds.hxx
+++ b/sw/inc/fmtclds.hxx
@@ -96,7 +96,7 @@ public:
virtual ~SwFormatCol();
//#i120133#
sal_Int16 GetAdjustValue() const { return m_aWidthAdjustValue; }
- void SetAdjustValue( const sal_Int16& n ) { m_aWidthAdjustValue = n; }
+ void SetAdjustValue( sal_Int16 n ) { m_aWidthAdjustValue = n; }
SwFormatCol& operator=( const SwFormatCol& );
diff --git a/sw/source/core/access/accpara.cxx b/sw/source/core/access/accpara.cxx
index e8b502a31fc9..beef3e26026a 100644
--- a/sw/source/core/access/accpara.cxx
+++ b/sw/source/core/access/accpara.cxx
@@ -1426,7 +1426,7 @@ struct IndexCompare
{
const PropertyValue* pValues;
explicit IndexCompare( const PropertyValue* pVals ) : pValues(pVals) {}
- bool operator() ( const sal_Int32& a, const sal_Int32& b ) const
+ bool operator() ( sal_Int32 a, sal_Int32 b ) const
{
return (pValues[a].Name < pValues[b].Name);
}
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index 8d0d0ebb9d2f..250bbc8d113a 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -512,7 +512,7 @@ public:
const OUString& GetHlink() const { return maHlink; }
void SetTarFrame( const OUString& rTarFrame ) { maTarFrame = rTarFrame; }
const OUString& GetTarFrame() const { return maTarFrame; }
- void SetShapeId( const sal_Int32& rShapeId ) { mnShapeId = rShapeId; }
+ void SetShapeId( sal_Int32 rShapeId ) { mnShapeId = rShapeId; }
const sal_Int32& GetShapeId() const { return mnShapeId; }
void SetName( const OUString& rName ) { maNameStr = rName; }
const OUString& GetName() const { return maNameStr; }
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index d962b3862c87..92782781756c 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -1026,7 +1026,7 @@ static SfxObjectShell* lcl_CreateWorkingDocument(
uno::Reference< mail::XMailMessage > lcl_CreateMailFromDoc(
const SwMergeDescriptor &rMergeDescriptor,
const OUString &sFileURL, const OUString &sMailRecipient,
- const OUString &sMailBodyMimeType, const rtl_TextEncoding &sMailEncoding,
+ const OUString &sMailBodyMimeType, rtl_TextEncoding sMailEncoding,
const OUString &sAttachmentMimeType )
{
SwMailMessage* pMessage = new SwMailMessage;
diff --git a/uui/source/iahndl-ssl.cxx b/uui/source/iahndl-ssl.cxx
index b583b1bcc0ea..20688f7a3c9f 100644
--- a/uui/source/iahndl-ssl.cxx
+++ b/uui/source/iahndl-ssl.cxx
@@ -179,7 +179,7 @@ executeSSLWarnDialog(
vcl::Window * pParent,
uno::Reference< uno::XComponentContext > const & xContext,
const uno::Reference< security::XCertificate >& rXCert,
- sal_Int32 const & failure,
+ sal_Int32 failure,
const OUString & hostName )
{
try
diff --git a/vcl/unx/generic/gdi/xrender_peer.hxx b/vcl/unx/generic/gdi/xrender_peer.hxx
index 1053bfd81b48..dbd6cb4955af 100644
--- a/vcl/unx/generic/gdi/xrender_peer.hxx
+++ b/vcl/unx/generic/gdi/xrender_peer.hxx
@@ -135,7 +135,7 @@ inline void XRenderPeer::CompositeTrapezoids( int nOp,
nXSrc, nYSrc, pXT, nCount );
}
-inline XRenderColor GetXRenderColor( const SalColor& rSalColor, double fTransparency = 0.0 )
+inline XRenderColor GetXRenderColor( SalColor rSalColor, double fTransparency = 0.0 )
{
XRenderColor aRetVal;
// convert the SalColor