diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-05 13:51:39 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-06 08:33:28 +0200 |
commit | 3d604d1cd6cc70ef96782ef769f0479b509987a8 (patch) | |
tree | 068bb54b87dd46640ff752994133692551118400 | |
parent | 16afac775a048d6d57d43952c855345f47cb231f (diff) |
clang-tidy performance-move-const-arg
Change-Id: I607891e120688b746c8a4c577018d97147a79217
Reviewed-on: https://gerrit.libreoffice.org/60029
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r-- | chart2/source/view/charttypes/VSeriesPlotter.cxx | 10 | ||||
-rw-r--r-- | editeng/source/editeng/eertfpar.cxx | 16 | ||||
-rw-r--r-- | editeng/source/items/frmitems.cxx | 22 | ||||
-rw-r--r-- | editeng/source/uno/unotext.cxx | 2 | ||||
-rw-r--r-- | l10ntools/source/po.cxx | 2 | ||||
-rw-r--r-- | oox/source/ppt/layoutfragmenthandler.cxx | 5 | ||||
-rw-r--r-- | sw/source/uibase/wrtsh/select.cxx | 2 | ||||
-rw-r--r-- | unotools/source/config/confignode.cxx | 4 | ||||
-rw-r--r-- | vcl/source/bitmap/bitmap.cxx | 2 | ||||
-rw-r--r-- | vcl/source/gdi/impgraph.cxx | 12 |
10 files changed, 39 insertions, 38 deletions
diff --git a/chart2/source/view/charttypes/VSeriesPlotter.cxx b/chart2/source/view/charttypes/VSeriesPlotter.cxx index 4b4602af7589..d9d4977d384a 100644 --- a/chart2/source/view/charttypes/VSeriesPlotter.cxx +++ b/chart2/source/view/charttypes/VSeriesPlotter.cxx @@ -116,11 +116,11 @@ VDataSeriesGroup::VDataSeriesGroup( std::unique_ptr<VDataSeries> pSeries ) m_aSeriesVector[0] = std::move(pSeries); } -VDataSeriesGroup::VDataSeriesGroup( VDataSeriesGroup&& other ) - : m_aSeriesVector( std::move(other.m_aSeriesVector) ) - , m_bMaxPointCountDirty( other.m_bMaxPointCountDirty ) - , m_nMaxPointCount( std::move(other.m_nMaxPointCount) ) - , m_aListOfCachedYValues( std::move(other.m_aListOfCachedYValues) ) +VDataSeriesGroup::VDataSeriesGroup(VDataSeriesGroup&& other) + : m_aSeriesVector(std::move(other.m_aSeriesVector)) + , m_bMaxPointCountDirty(other.m_bMaxPointCountDirty) + , m_nMaxPointCount(other.m_nMaxPointCount) + , m_aListOfCachedYValues(std::move(other.m_aListOfCachedYValues)) { } diff --git a/editeng/source/editeng/eertfpar.cxx b/editeng/source/editeng/eertfpar.cxx index ccecfa5723de..16f202d24a28 100644 --- a/editeng/source/editeng/eertfpar.cxx +++ b/editeng/source/editeng/eertfpar.cxx @@ -62,14 +62,14 @@ RtfImportInfo::~RtfImportInfo() { } -EditRTFParser::EditRTFParser( - SvStream& rIn, EditSelection aSel, SfxItemPool& rAttrPool, EditEngine* pEditEngine) : - SvxRTFParser(rAttrPool, rIn), - aCurSel(std::move(aSel)), - mpEditEngine(pEditEngine), - aRTFMapMode(MapUnit::MapTwip), - nDefFont(0), - bLastActionInsertParaBreak(false) +EditRTFParser::EditRTFParser(SvStream& rIn, EditSelection aSel, SfxItemPool& rAttrPool, + EditEngine* pEditEngine) + : SvxRTFParser(rAttrPool, rIn) + , aCurSel(aSel) + , mpEditEngine(pEditEngine) + , aRTFMapMode(MapUnit::MapTwip) + , nDefFont(0) + , bLastActionInsertParaBreak(false) { SetInsPos(EditPosition(mpEditEngine, &aCurSel)); diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index e690d36ffb85..2c40069d5d47 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -3241,15 +3241,15 @@ SvxBrushItem::SvxBrushItem(const SvxBrushItem& rItem) } SvxBrushItem::SvxBrushItem(SvxBrushItem&& rItem) - : SfxPoolItem(std::move(rItem)) - , aColor(std::move(rItem.aColor)) - , nShadingValue(std::move(rItem.nShadingValue)) + : SfxPoolItem(rItem) + , aColor(rItem.aColor) + , nShadingValue(rItem.nShadingValue) , xGraphicObject(std::move(rItem.xGraphicObject)) - , nGraphicTransparency(std::move(rItem.nGraphicTransparency)) + , nGraphicTransparency(rItem.nGraphicTransparency) , maStrLink(std::move(rItem.maStrLink)) , maStrFilter(std::move(rItem.maStrFilter)) - , eGraphicPos(std::move(rItem.eGraphicPos)) - , bLoadAgain(std::move(rItem.bLoadAgain)) + , eGraphicPos(rItem.eGraphicPos) + , bLoadAgain(rItem.bLoadAgain) { } @@ -3519,14 +3519,14 @@ SvxBrushItem& SvxBrushItem::operator=(const SvxBrushItem& rItem) SvxBrushItem& SvxBrushItem::operator=(SvxBrushItem&& rItem) { - aColor = std::move(rItem.aColor); - nShadingValue = std::move(rItem.nShadingValue); + aColor = rItem.aColor; + nShadingValue = rItem.nShadingValue; xGraphicObject = std::move(rItem.xGraphicObject); - nGraphicTransparency = std::move(rItem.nGraphicTransparency); + nGraphicTransparency = rItem.nGraphicTransparency; maStrLink = std::move(rItem.maStrLink); maStrFilter = std::move(rItem.maStrFilter); - eGraphicPos = std::move(rItem.eGraphicPos); - bLoadAgain = std::move(rItem.bLoadAgain); + eGraphicPos = rItem.eGraphicPos; + bLoadAgain = rItem.bLoadAgain; return *this; } diff --git a/editeng/source/uno/unotext.cxx b/editeng/source/uno/unotext.cxx index 22699090a93c..4e52a5099a9f 100644 --- a/editeng/source/uno/unotext.cxx +++ b/editeng/source/uno/unotext.cxx @@ -287,7 +287,7 @@ void SvxUnoTextRangeBase::attachField( std::unique_ptr<SvxFieldData> pData ) thr if( pForwarder ) { SvxFieldItem aField( std::move(pData), EE_FEATURE_FIELD ); - pForwarder->QuickInsertField( std::move(aField), maSelection ); + pForwarder->QuickInsertField(aField, maSelection); } } diff --git a/l10ntools/source/po.cxx b/l10ntools/source/po.cxx index 72644095c8f8..48ec1a68ecf0 100644 --- a/l10ntools/source/po.cxx +++ b/l10ntools/source/po.cxx @@ -287,7 +287,7 @@ PoEntry& PoEntry::operator=(const PoEntry& rPo) PoEntry& PoEntry::operator=(PoEntry&& rPo) { m_pGenPo = std::move(rPo.m_pGenPo); - m_bIsInitialized = std::move(rPo.m_bIsInitialized); + m_bIsInitialized = rPo.m_bIsInitialized; return *this; } diff --git a/oox/source/ppt/layoutfragmenthandler.cxx b/oox/source/ppt/layoutfragmenthandler.cxx index 2c22ba948577..e73a33e1d0c1 100644 --- a/oox/source/ppt/layoutfragmenthandler.cxx +++ b/oox/source/ppt/layoutfragmenthandler.cxx @@ -41,8 +41,9 @@ namespace oox { namespace ppt { // CT_SlideLayout -LayoutFragmentHandler::LayoutFragmentHandler(XmlFilterBase& rFilter, const OUString& rFragmentPath, SlidePersistPtr pMasterPersistPtr) -: SlideFragmentHandler( rFilter, rFragmentPath, std::move(pMasterPersistPtr), Layout ) +LayoutFragmentHandler::LayoutFragmentHandler(XmlFilterBase& rFilter, const OUString& rFragmentPath, + SlidePersistPtr pMasterPersistPtr) + : SlideFragmentHandler(rFilter, rFragmentPath, pMasterPersistPtr, Layout) { } diff --git a/sw/source/uibase/wrtsh/select.cxx b/sw/source/uibase/wrtsh/select.cxx index 3f4c2540f006..70433e8de070 100644 --- a/sw/source/uibase/wrtsh/select.cxx +++ b/sw/source/uibase/wrtsh/select.cxx @@ -296,7 +296,7 @@ void SwWrtShell::PopMode() LeaveBlockMode(); m_bIns = m_pModeStack->bIns; - m_pModeStack = std::move(m_pModeStack->pNext); + m_pModeStack = m_pModeStack->pNext; } // Two methods for setting cursors: the first maps at the diff --git a/unotools/source/config/confignode.cxx b/unotools/source/config/confignode.cxx index 66d44cdc8301..fa94fc51a508 100644 --- a/unotools/source/config/confignode.cxx +++ b/unotools/source/config/confignode.cxx @@ -97,7 +97,7 @@ namespace utl , m_xDirectAccess(std::move(_rSource.m_xDirectAccess)) , m_xReplaceAccess(std::move(_rSource.m_xReplaceAccess)) , m_xContainerAccess(std::move(_rSource.m_xContainerAccess)) - , m_bEscapeNames(std::move(_rSource.m_bEscapeNames)) + , m_bEscapeNames(_rSource.m_bEscapeNames) { Reference< XComponent > xConfigNodeComp(m_xDirectAccess, UNO_QUERY); if (xConfigNodeComp.is()) @@ -129,7 +129,7 @@ namespace utl m_xDirectAccess = std::move(_rSource.m_xDirectAccess); m_xContainerAccess = std::move(_rSource.m_xContainerAccess); m_xReplaceAccess = std::move(_rSource.m_xReplaceAccess); - m_bEscapeNames = std::move(_rSource.m_bEscapeNames); + m_bEscapeNames = _rSource.m_bEscapeNames; Reference< XComponent > xConfigNodeComp(m_xDirectAccess, UNO_QUERY); if (xConfigNodeComp.is()) diff --git a/vcl/source/bitmap/bitmap.cxx b/vcl/source/bitmap/bitmap.cxx index 2de0da7b1a72..b0b59906f0da 100644 --- a/vcl/source/bitmap/bitmap.cxx +++ b/vcl/source/bitmap/bitmap.cxx @@ -221,7 +221,7 @@ Bitmap& Bitmap::operator=( const Bitmap& rBitmap ) Bitmap& Bitmap::operator=( Bitmap&& rBitmap ) { - maPrefSize = std::move(rBitmap.maPrefSize); + maPrefSize = rBitmap.maPrefSize; maPrefMapMode = std::move(rBitmap.maPrefMapMode); mxSalBmp = std::move(rBitmap.mxSalBmp); diff --git a/vcl/source/gdi/impgraph.cxx b/vcl/source/gdi/impgraph.cxx index 005427b66dce..49af5af45bf2 100644 --- a/vcl/source/gdi/impgraph.cxx +++ b/vcl/source/gdi/impgraph.cxx @@ -212,8 +212,8 @@ ImpGraphic::ImpGraphic(const ImpGraphic& rImpGraphic) } ImpGraphic::ImpGraphic(ImpGraphic&& rImpGraphic) - : maMetaFile(std::move(rImpGraphic.maMetaFile)) - , maEx(std::move(rImpGraphic.maEx)) + : maMetaFile(rImpGraphic.maMetaFile) + , maEx(rImpGraphic.maEx) , maSwapInfo(std::move(rImpGraphic.maSwapInfo)) , mpAnimation(std::move(rImpGraphic.mpAnimation)) , mpContext(std::move(rImpGraphic.mpContext)) @@ -226,8 +226,8 @@ ImpGraphic::ImpGraphic(ImpGraphic&& rImpGraphic) , maVectorGraphicData(std::move(rImpGraphic.maVectorGraphicData)) , mpPdfData(std::move(rImpGraphic.mpPdfData)) , maGraphicExternalLink(rImpGraphic.maGraphicExternalLink) - , maLastUsed (std::chrono::high_resolution_clock::now()) - , mbPrepared (rImpGraphic.mbPrepared) + , maLastUsed(std::chrono::high_resolution_clock::now()) + , mbPrepared(rImpGraphic.mbPrepared) , mnPageNumber(rImpGraphic.mnPageNumber) { rImpGraphic.ImplClear(); @@ -360,7 +360,7 @@ ImpGraphic& ImpGraphic::operator=(ImpGraphic&& rImpGraphic) { sal_Int64 aOldSizeBytes = mnSizeBytes; - maMetaFile = std::move(rImpGraphic.maMetaFile); + maMetaFile = rImpGraphic.maMetaFile; meType = rImpGraphic.meType; mnSizeBytes = rImpGraphic.mnSizeBytes; maSwapInfo = std::move(rImpGraphic.maSwapInfo); @@ -368,7 +368,7 @@ ImpGraphic& ImpGraphic::operator=(ImpGraphic&& rImpGraphic) mbDummyContext = rImpGraphic.mbDummyContext; mnPageNumber = rImpGraphic.mnPageNumber; mpAnimation = std::move(rImpGraphic.mpAnimation); - maEx = std::move(rImpGraphic.maEx); + maEx = rImpGraphic.maEx; mbSwapOut = rImpGraphic.mbSwapOut; mpSwapFile = std::move(rImpGraphic.mpSwapFile); mpGfxLink = std::move(rImpGraphic.mpGfxLink); |