aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/scenegraph
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2022-10-27 08:18:25 -0700
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2022-10-28 22:25:27 +0000
commita2c4d27cf9b4992fca6a30e01d31c0a5305b7123 (patch)
treebe64663c48a79642ef386bef34dae225941e8f94 /src/quick/scenegraph
parent26be677f84264d84fa6924f7cc4641552a6479f4 (diff)
QSGGeometry: add Q_DISABLE_COPY_MOVE
This is a polymorphic class, so that already tells us this should never be copied. Moreover, it has a reference member, so the default assignment operator cannot be instantiated. error: use of deleted function ‘QSGGeometry& QSGGeometry::operator=(const QSGGeometry&)’ qsggeometry.h:51:22: note: ‘QSGGeometry& QSGGeometry::operator=(const QSGGeometry&)’ is implicitly deleted because the default definition would be ill-formed: qsggeometry.h:51:22: error: non-static reference member ‘const QSGGeometry::AttributeSet& QSGGeometry::m_attributes’, cannot use default assignment operator Found while compiling PyQt, which is obviously wrong, but this should improve the error message output. Change-Id: I07ec23f3cb174fb197c3fffd1721f614929a18f4 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit 32b71a40cdbcd77956b309b032caafa02abcc13f) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'src/quick/scenegraph')
-rw-r--r--src/quick/scenegraph/coreapi/qsggeometry.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/quick/scenegraph/coreapi/qsggeometry.h b/src/quick/scenegraph/coreapi/qsggeometry.h
index 64085393f9..7ea2aa1027 100644
--- a/src/quick/scenegraph/coreapi/qsggeometry.h
+++ b/src/quick/scenegraph/coreapi/qsggeometry.h
@@ -202,6 +202,7 @@ public:
void setLineWidth(float w);
private:
+ Q_DISABLE_COPY_MOVE(QSGGeometry)
friend class QSGGeometryData;
int m_drawing_mode;