basegfx/source/curve/b2dcubicbezier.cxx   |   26 +++----------------------
 basegfx/source/matrix/b2dhommatrix.cxx    |   31 +++++-------------------------
 basegfx/source/matrix/b3dhommatrix.cxx    |   31 +++++-------------------------
 basegfx/source/polygon/b2dpolygon.cxx     |   28 +++++----------------------
 basegfx/source/polygon/b2dpolypolygon.cxx |   31 +++++-------------------------
 basegfx/source/polygon/b3dpolygon.cxx     |   26 ++++---------------------
 basegfx/source/polygon/b3dpolypolygon.cxx |   26 ++++---------------------
 basegfx/source/range/b2dpolyrange.cxx     |   17 +++-------------
 basegfx/source/tools/b2dclipstate.cxx     |   27 +++++---------------------
 9 files changed, 48 insertions(+), 195 deletions(-)

New commits:
commit b3e0ef4cacfa63be7a6d4f152f197d07a3bbe255
Author: Jochen Nitschke <j.nitschke+loger...@ok.de>
Date:   Sat Apr 21 17:02:04 2018 +0200

    clang-tidy modernize-use-equals-default in basegfx
    
    Change-Id: If4ee51e022eba1f9f36c262abf9ba407db2b158e
    Reviewed-on: https://gerrit.libreoffice.org/53260
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>

diff --git a/basegfx/source/curve/b2dcubicbezier.cxx 
b/basegfx/source/curve/b2dcubicbezier.cxx
index d8f03de46c33..db2c7baed0b1 100644
--- a/basegfx/source/curve/b2dcubicbezier.cxx
+++ b/basegfx/source/curve/b2dcubicbezier.cxx
@@ -325,17 +325,9 @@ namespace basegfx
 
 namespace basegfx
 {
-    B2DCubicBezier::B2DCubicBezier(const B2DCubicBezier& rBezier)
-    :   maStartPoint(rBezier.maStartPoint),
-        maEndPoint(rBezier.maEndPoint),
-        maControlPointA(rBezier.maControlPointA),
-        maControlPointB(rBezier.maControlPointB)
-    {
-    }
+    B2DCubicBezier::B2DCubicBezier(const B2DCubicBezier&) = default;
 
-    B2DCubicBezier::B2DCubicBezier()
-    {
-    }
+    B2DCubicBezier::B2DCubicBezier() = default;
 
     B2DCubicBezier::B2DCubicBezier(const B2DPoint& rStart, const B2DPoint& 
rControlPointA, const B2DPoint& rControlPointB, const B2DPoint& rEnd)
     :   maStartPoint(rStart),
@@ -345,20 +337,10 @@ namespace basegfx
     {
     }
 
-    B2DCubicBezier::~B2DCubicBezier()
-    {
-    }
+    B2DCubicBezier::~B2DCubicBezier() = default;
 
     // assignment operator
-    B2DCubicBezier& B2DCubicBezier::operator=(const B2DCubicBezier& rBezier)
-    {
-        maStartPoint = rBezier.maStartPoint;
-        maEndPoint = rBezier.maEndPoint;
-        maControlPointA = rBezier.maControlPointA;
-        maControlPointB = rBezier.maControlPointB;
-
-        return *this;
-    }
+    B2DCubicBezier& B2DCubicBezier::operator=(const B2DCubicBezier&) = default;
 
     // compare operators
     bool B2DCubicBezier::operator==(const B2DCubicBezier& rBezier) const
diff --git a/basegfx/source/matrix/b2dhommatrix.cxx 
b/basegfx/source/matrix/b2dhommatrix.cxx
index 466e9037d149..053ca89d02de 100644
--- a/basegfx/source/matrix/b2dhommatrix.cxx
+++ b/basegfx/source/matrix/b2dhommatrix.cxx
@@ -31,24 +31,13 @@ namespace basegfx
     {
     };
 
-    B2DHomMatrix::B2DHomMatrix()
-        : mpImpl() // identity
-    {
-    }
+    B2DHomMatrix::B2DHomMatrix() = default;
 
-    B2DHomMatrix::B2DHomMatrix(const B2DHomMatrix& rMat) :
-        mpImpl(rMat.mpImpl)
-    {
-    }
+    B2DHomMatrix::B2DHomMatrix(const B2DHomMatrix&) = default;
 
-    B2DHomMatrix::B2DHomMatrix(B2DHomMatrix&& rMat) :
-        mpImpl(std::move(rMat.mpImpl))
-    {
-    }
+    B2DHomMatrix::B2DHomMatrix(B2DHomMatrix&&) = default;
 
-    B2DHomMatrix::~B2DHomMatrix()
-    {
-    }
+    B2DHomMatrix::~B2DHomMatrix() = default;
 
     B2DHomMatrix::B2DHomMatrix(double f_0x0, double f_0x1, double f_0x2, 
double f_1x0, double f_1x1, double f_1x2)
         :   mpImpl() // identity
@@ -61,17 +50,9 @@ namespace basegfx
         mpImpl->set(1, 2, f_1x2);
     }
 
-    B2DHomMatrix& B2DHomMatrix::operator=(const B2DHomMatrix& rMat)
-    {
-        mpImpl = rMat.mpImpl;
-        return *this;
-    }
+    B2DHomMatrix& B2DHomMatrix::operator=(const B2DHomMatrix&) = default;
 
-    B2DHomMatrix& B2DHomMatrix::operator=(B2DHomMatrix&& rMat)
-    {
-        mpImpl = std::move(rMat.mpImpl);
-        return *this;
-    }
+    B2DHomMatrix& B2DHomMatrix::operator=(B2DHomMatrix&&) = default;
 
     double B2DHomMatrix::get(sal_uInt16 nRow, sal_uInt16 nColumn) const
     {
diff --git a/basegfx/source/matrix/b3dhommatrix.cxx 
b/basegfx/source/matrix/b3dhommatrix.cxx
index b55dd079b514..2e5e798fb001 100644
--- a/basegfx/source/matrix/b3dhommatrix.cxx
+++ b/basegfx/source/matrix/b3dhommatrix.cxx
@@ -29,36 +29,17 @@ namespace basegfx
     {
     };
 
-    B3DHomMatrix::B3DHomMatrix()
-        : mpImpl() // identity
-    {
-    }
+    B3DHomMatrix::B3DHomMatrix() = default;
 
-    B3DHomMatrix::B3DHomMatrix(const B3DHomMatrix& rMat) :
-        mpImpl(rMat.mpImpl)
-    {
-    }
+    B3DHomMatrix::B3DHomMatrix(const B3DHomMatrix&) = default;
 
-    B3DHomMatrix::B3DHomMatrix(B3DHomMatrix&& rMat) :
-        mpImpl(std::move(rMat.mpImpl))
-    {
-    }
+    B3DHomMatrix::B3DHomMatrix(B3DHomMatrix&&) = default;
 
-    B3DHomMatrix::~B3DHomMatrix()
-    {
-    }
+    B3DHomMatrix::~B3DHomMatrix() = default;
 
-    B3DHomMatrix& B3DHomMatrix::operator=(const B3DHomMatrix& rMat)
-    {
-        mpImpl = rMat.mpImpl;
-        return *this;
-    }
+    B3DHomMatrix& B3DHomMatrix::operator=(const B3DHomMatrix&) = default;
 
-    B3DHomMatrix& B3DHomMatrix::operator=(B3DHomMatrix&& rMat)
-    {
-        mpImpl = std::move(rMat.mpImpl);
-        return *this;
-    }
+    B3DHomMatrix& B3DHomMatrix::operator=(B3DHomMatrix&&) = default;
 
     double B3DHomMatrix::get(sal_uInt16 nRow, sal_uInt16 nColumn) const
     {
diff --git a/basegfx/source/polygon/b2dpolygon.cxx 
b/basegfx/source/polygon/b2dpolygon.cxx
index 1a4d4a76da0c..9372cb3d9038 100644
--- a/basegfx/source/polygon/b2dpolygon.cxx
+++ b/basegfx/source/polygon/b2dpolygon.cxx
@@ -1104,9 +1104,7 @@ public:
 
 namespace basegfx
 {
-    B2DPolygon::B2DPolygon()
-        : mpPolygon()
-    {}
+    B2DPolygon::B2DPolygon() = default;
 
     B2DPolygon::B2DPolygon(std::initializer_list<basegfx::B2DPoint> aPoints)
         : mpPolygon()
@@ -1117,13 +1115,9 @@ namespace basegfx
         }
     }
 
-    B2DPolygon::B2DPolygon(const B2DPolygon& rPolygon)
-    :   mpPolygon(rPolygon.mpPolygon)
-    {}
+    B2DPolygon::B2DPolygon(const B2DPolygon&) = default;
 
-    B2DPolygon::B2DPolygon(B2DPolygon&& rPolygon)
-    :   mpPolygon(std::move(rPolygon.mpPolygon))
-    {}
+    B2DPolygon::B2DPolygon(B2DPolygon&&) = default;
 
     B2DPolygon::B2DPolygon(const B2DPolygon& rPolygon, sal_uInt32 nIndex, 
sal_uInt32 nCount)
     :   mpPolygon(ImplB2DPolygon(*rPolygon.mpPolygon, nIndex, nCount))
@@ -1133,21 +1127,11 @@ namespace basegfx
         OSL_ENSURE(nIndex + nCount <= rPolygon.mpPolygon->count(), "B2DPolygon 
constructor outside range (!)");
     }
 
-    B2DPolygon::~B2DPolygon()
-    {
-    }
+    B2DPolygon::~B2DPolygon() = default;
 
-    B2DPolygon& B2DPolygon::operator=(const B2DPolygon& rPolygon)
-    {
-        mpPolygon = rPolygon.mpPolygon;
-        return *this;
-    }
+    B2DPolygon& B2DPolygon::operator=(const B2DPolygon&) = default;
 
-    B2DPolygon& B2DPolygon::operator=(B2DPolygon&& rPolygon)
-    {
-        mpPolygon = std::move(rPolygon.mpPolygon);
-        return *this;
-    }
+    B2DPolygon& B2DPolygon::operator=(B2DPolygon&&) = default;
 
     void B2DPolygon::makeUnique()
     {
diff --git a/basegfx/source/polygon/b2dpolypolygon.cxx 
b/basegfx/source/polygon/b2dpolypolygon.cxx
index b0a51d46a3a7..a1ac5301c178 100644
--- a/basegfx/source/polygon/b2dpolypolygon.cxx
+++ b/basegfx/source/polygon/b2dpolypolygon.cxx
@@ -170,41 +170,22 @@ public:
 namespace basegfx
 {
 
-    B2DPolyPolygon::B2DPolyPolygon()
-        : mpPolyPolygon()
-    {
-    }
+    B2DPolyPolygon::B2DPolyPolygon() = default;
 
-    B2DPolyPolygon::B2DPolyPolygon(const B2DPolyPolygon& rPolyPolygon) :
-        mpPolyPolygon(rPolyPolygon.mpPolyPolygon)
-    {
-    }
+    B2DPolyPolygon::B2DPolyPolygon(const B2DPolyPolygon&) = default;
 
-    B2DPolyPolygon::B2DPolyPolygon(B2DPolyPolygon&& rPolyPolygon) :
-        mpPolyPolygon(std::move(rPolyPolygon.mpPolyPolygon))
-    {
-    }
+    B2DPolyPolygon::B2DPolyPolygon(B2DPolyPolygon&&) = default;
 
     B2DPolyPolygon::B2DPolyPolygon(const B2DPolygon& rPolygon) :
         mpPolyPolygon( ImplB2DPolyPolygon(rPolygon) )
     {
     }
 
-    B2DPolyPolygon::~B2DPolyPolygon()
-    {
-    }
+    B2DPolyPolygon::~B2DPolyPolygon() = default;
 
-    B2DPolyPolygon& B2DPolyPolygon::operator=(const B2DPolyPolygon& 
rPolyPolygon)
-    {
-        mpPolyPolygon = rPolyPolygon.mpPolyPolygon;
-        return *this;
-    }
+    B2DPolyPolygon& B2DPolyPolygon::operator=(const B2DPolyPolygon&) = default;
 
-    B2DPolyPolygon& B2DPolyPolygon::operator=(B2DPolyPolygon&& rPolyPolygon)
-    {
-        mpPolyPolygon = std::move(rPolyPolygon.mpPolyPolygon);
-        return *this;
-    }
+    B2DPolyPolygon& B2DPolyPolygon::operator=(B2DPolyPolygon&&) = default;
 
     void B2DPolyPolygon::makeUnique()
     {
diff --git a/basegfx/source/polygon/b3dpolygon.cxx 
b/basegfx/source/polygon/b3dpolygon.cxx
index fc0ef2c23f22..1f2e6ebea67a 100644
--- a/basegfx/source/polygon/b3dpolygon.cxx
+++ b/basegfx/source/polygon/b3dpolygon.cxx
@@ -1414,31 +1414,15 @@ namespace basegfx
     {
     }
 
-    B3DPolygon::B3DPolygon(const B3DPolygon& rPolygon) :
-        mpPolygon(rPolygon.mpPolygon)
-    {
-    }
+    B3DPolygon::B3DPolygon(const B3DPolygon&) = default;
 
-    B3DPolygon::B3DPolygon(B3DPolygon&& rPolygon) :
-        mpPolygon(std::move(rPolygon.mpPolygon))
-    {
-    }
+    B3DPolygon::B3DPolygon(B3DPolygon&&) = default;
 
-    B3DPolygon::~B3DPolygon()
-    {
-    }
+    B3DPolygon::~B3DPolygon() = default;
 
-    B3DPolygon& B3DPolygon::operator=(const B3DPolygon& rPolygon)
-    {
-        mpPolygon = rPolygon.mpPolygon;
-        return *this;
-    }
+    B3DPolygon& B3DPolygon::operator=(const B3DPolygon&) = default;
 
-    B3DPolygon& B3DPolygon::operator=(B3DPolygon&& rPolygon)
-    {
-        mpPolygon = std::move(rPolygon.mpPolygon);
-        return *this;
-    }
+    B3DPolygon& B3DPolygon::operator=(B3DPolygon&&) = default;
 
     bool B3DPolygon::operator==(const B3DPolygon& rPolygon) const
     {
diff --git a/basegfx/source/polygon/b3dpolypolygon.cxx 
b/basegfx/source/polygon/b3dpolypolygon.cxx
index 37186aea94b3..b7ea0b36631e 100644
--- a/basegfx/source/polygon/b3dpolypolygon.cxx
+++ b/basegfx/source/polygon/b3dpolypolygon.cxx
@@ -196,36 +196,20 @@ namespace basegfx
     {
     }
 
-    B3DPolyPolygon::B3DPolyPolygon(const B3DPolyPolygon& rPolyPolygon) :
-        mpPolyPolygon(rPolyPolygon.mpPolyPolygon)
-    {
-    }
+    B3DPolyPolygon::B3DPolyPolygon(const B3DPolyPolygon&) = default;
 
-    B3DPolyPolygon::B3DPolyPolygon(B3DPolyPolygon&& rPolyPolygon) :
-        mpPolyPolygon(std::move(rPolyPolygon.mpPolyPolygon))
-    {
-    }
+    B3DPolyPolygon::B3DPolyPolygon(B3DPolyPolygon&&) = default;
 
     B3DPolyPolygon::B3DPolyPolygon(const B3DPolygon& rPolygon) :
         mpPolyPolygon( ImplB3DPolyPolygon(rPolygon) )
     {
     }
 
-    B3DPolyPolygon::~B3DPolyPolygon()
-    {
-    }
+    B3DPolyPolygon::~B3DPolyPolygon() = default;
 
-    B3DPolyPolygon& B3DPolyPolygon::operator=(const B3DPolyPolygon& 
rPolyPolygon)
-    {
-        mpPolyPolygon = rPolyPolygon.mpPolyPolygon;
-        return *this;
-    }
+    B3DPolyPolygon& B3DPolyPolygon::operator=(const B3DPolyPolygon&) = default;
 
-    B3DPolyPolygon& B3DPolyPolygon::operator=(B3DPolyPolygon&& rPolyPolygon)
-    {
-        mpPolyPolygon = std::move(rPolyPolygon.mpPolyPolygon);
-        return *this;
-    }
+    B3DPolyPolygon& B3DPolyPolygon::operator=(B3DPolyPolygon&&) = default;
 
     bool B3DPolyPolygon::operator==(const B3DPolyPolygon& rPolyPolygon) const
     {
diff --git a/basegfx/source/range/b2dpolyrange.cxx 
b/basegfx/source/range/b2dpolyrange.cxx
index a98578ee974d..aedc1800dddb 100644
--- a/basegfx/source/range/b2dpolyrange.cxx
+++ b/basegfx/source/range/b2dpolyrange.cxx
@@ -100,22 +100,13 @@ namespace basegfx
         std::vector<B2VectorOrientation> maOrient;
     };
 
-    B2DPolyRange::B2DPolyRange() :
-        mpImpl()
-    {}
+    B2DPolyRange::B2DPolyRange() = default;
 
-    B2DPolyRange::~B2DPolyRange()
-    {}
+    B2DPolyRange::~B2DPolyRange() = default;
 
-    B2DPolyRange::B2DPolyRange( const B2DPolyRange& rRange ) :
-        mpImpl( rRange.mpImpl )
-    {}
+    B2DPolyRange::B2DPolyRange( const B2DPolyRange& ) = default;
 
-    B2DPolyRange& B2DPolyRange::operator=( const B2DPolyRange& rRange )
-    {
-        mpImpl = rRange.mpImpl;
-        return *this;
-    }
+    B2DPolyRange& B2DPolyRange::operator=( const B2DPolyRange& ) = default;
 
     bool B2DPolyRange::operator==(const B2DPolyRange& rRange) const
     {
diff --git a/basegfx/source/tools/b2dclipstate.cxx 
b/basegfx/source/tools/b2dclipstate.cxx
index cff66f93faf9..9459e60d03f7 100644
--- a/basegfx/source/tools/b2dclipstate.cxx
+++ b/basegfx/source/tools/b2dclipstate.cxx
@@ -388,36 +388,21 @@ namespace utils
         mutable Operation      mePendingOps;
     };
 
-    B2DClipState::B2DClipState() :
-        mpImpl()
-    {}
+    B2DClipState::B2DClipState() = default;
 
-    B2DClipState::~B2DClipState()
-    {}
+    B2DClipState::~B2DClipState() = default;
 
-    B2DClipState::B2DClipState( const B2DClipState& rOrig ) :
-        mpImpl(rOrig.mpImpl)
-    {}
+    B2DClipState::B2DClipState( const B2DClipState& ) = default;
 
-    B2DClipState::B2DClipState( B2DClipState&& rOrig ) :
-        mpImpl(std::move(rOrig.mpImpl))
-    {}
+    B2DClipState::B2DClipState( B2DClipState&& ) = default;
 
     B2DClipState::B2DClipState( const B2DPolyPolygon& rPolyPoly ) :
         mpImpl( ImplB2DClipState(rPolyPoly) )
     {}
 
-    B2DClipState& B2DClipState::operator=( const B2DClipState& rRHS )
-    {
-        mpImpl = rRHS.mpImpl;
-        return *this;
-    }
+    B2DClipState& B2DClipState::operator=( const B2DClipState& ) = default;
 
-    B2DClipState& B2DClipState::operator=( B2DClipState&& rRHS )
-    {
-        mpImpl = std::move(rRHS.mpImpl);
-        return *this;
-    }
+    B2DClipState& B2DClipState::operator=( B2DClipState&& ) = default;
 
     void B2DClipState::makeNull()
     {
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to