From e445f3c47bea3e2d3dffa1215b24cb90dccd8c73 Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 21 Apr 2015 16:25:25 +0200 Subject: Add noexcept to move constructors and assignment operators Add the noexcept attribute to all move constructors and assignment operators in QtGui that didn't already have it. Change-Id: Idcdf79ae8349b8793e7394b5ae7c08e6111fbc9a Reviewed-by: Konstantin Ritt Reviewed-by: Gunnar Sletta --- src/gui/image/qpixmap.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/gui/image/qpixmap.h') diff --git a/src/gui/image/qpixmap.h b/src/gui/image/qpixmap.h index 810883ea6c..51b02acfcf 100644 --- a/src/gui/image/qpixmap.h +++ b/src/gui/image/qpixmap.h @@ -67,10 +67,11 @@ public: QPixmap &operator=(const QPixmap &); #ifdef Q_COMPILER_RVALUE_REFS - inline QPixmap &operator=(QPixmap &&other) + inline QPixmap &operator=(QPixmap &&other) Q_DECL_NOEXCEPT { qSwap(data, other.data); return *this; } #endif - inline void swap(QPixmap &other) { qSwap(data, other.data); } + inline void swap(QPixmap &other) Q_DECL_NOEXCEPT + { qSwap(data, other.data); } operator QVariant() const; -- cgit v1.2.3