diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-10-23 09:47:38 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-10-24 08:37:51 +0200 |
commit | f31c9f16fefd16ea434cdd68721d45bced9b78e1 (patch) | |
tree | c0c504cb4e4d41e168f7118c1baee6b4091aa51d /test | |
parent | 645db9a2643832e29dbdf904e1cf7b323d273f86 (diff) |
clang-tidy performance-unnecessary-copy-init in test..xmlscript
Change-Id: I1ae16467a8e58e8a50f59b7a140e9f8b68bde07e
Reviewed-on: https://gerrit.libreoffice.org/62254
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'test')
-rw-r--r-- | test/source/beans/xpropertyset.cxx | 2 | ||||
-rw-r--r-- | test/source/mtfxmldump.cxx | 1 | ||||
-rw-r--r-- | test/source/primitive2dxmldump.cxx | 6 |
3 files changed, 4 insertions, 5 deletions
diff --git a/test/source/beans/xpropertyset.cxx b/test/source/beans/xpropertyset.cxx index 63969e844005..2da14e7cdf6d 100644 --- a/test/source/beans/xpropertyset.cxx +++ b/test/source/beans/xpropertyset.cxx @@ -76,7 +76,7 @@ bool XPropertySet::isPropertyValueChangeable(const OUString& rName) try { uno::Any any = xPropSet->getPropertyValue(rName); - uno::Type type = any.getValueType(); + const uno::Type& type = any.getValueType(); if (type == cppu::UnoType<bool>::get()) { // boolean type diff --git a/test/source/mtfxmldump.cxx b/test/source/mtfxmldump.cxx index b298f736f57f..e54c78c5f1d6 100644 --- a/test/source/mtfxmldump.cxx +++ b/test/source/mtfxmldump.cxx @@ -541,7 +541,6 @@ void MetafileXmlDump::writeXml(const GDIMetaFile& rMetaFile, tools::XmlWriter& r writeStartPoint(rWriter, pMetaLineAction->GetStartPoint()); writeEndPoint(rWriter, pMetaLineAction->GetEndPoint()); - LineInfo aLineInfo = pMetaLineAction->GetLineInfo(); writeLineInfo(rWriter, pMetaLineAction->GetLineInfo()); rWriter.endElement(); } diff --git a/test/source/primitive2dxmldump.cxx b/test/source/primitive2dxmldump.cxx index 4f5c63ed54a9..fa2b02d4e2cf 100644 --- a/test/source/primitive2dxmldump.cxx +++ b/test/source/primitive2dxmldump.cxx @@ -127,7 +127,7 @@ void Primitive2dXmlDump::decomposeAndWrite( rWriter.startElement("polypolygoncolor"); rWriter.attribute("color", convertColorToString(rPolyPolygonColorPrimitive2D.getBColor())); - const basegfx::B2DPolyPolygon aB2DPolyPolygon(rPolyPolygonColorPrimitive2D.getB2DPolyPolygon()); + const basegfx::B2DPolyPolygon& aB2DPolyPolygon(rPolyPolygonColorPrimitive2D.getB2DPolyPolygon()); const basegfx::B2DRange aB2DRange(aB2DPolyPolygon.getB2DRange()); rWriter.attribute("height", aB2DRange.getHeight()); rWriter.attribute("width", aB2DRange.getWidth()); @@ -148,7 +148,7 @@ void Primitive2dXmlDump::decomposeAndWrite( rWriter.startElement("polypolygonstroke"); rWriter.startElement("line"); - drawinglayer::attribute::LineAttribute aLineAttribute = rPolyPolygonStrokePrimitive2D.getLineAttribute(); + const drawinglayer::attribute::LineAttribute& aLineAttribute = rPolyPolygonStrokePrimitive2D.getLineAttribute(); rWriter.attribute("color", convertColorToString(aLineAttribute.getColor())); rWriter.attribute("width", aLineAttribute.getWidth()); //rWriter.attribute("linejoin", aLineAttribute.getLineJoin()); @@ -197,7 +197,7 @@ void Primitive2dXmlDump::decomposeAndWrite( rWriter.attribute("text", rTextSimplePortionPrimitive2D.getText()); rWriter.attribute("fontcolor", convertColorToString(rTextSimplePortionPrimitive2D.getFontColor())); - drawinglayer::attribute::FontAttribute aFontAttribute = rTextSimplePortionPrimitive2D.getFontAttribute(); + const drawinglayer::attribute::FontAttribute& aFontAttribute = rTextSimplePortionPrimitive2D.getFontAttribute(); rWriter.attribute("familyname", aFontAttribute.getFamilyName()); rWriter.endElement(); } |