From a1e62e7ba14b00ac7c361936a18e7bc42bf1286d Mon Sep 17 00:00:00 2001 From: Allan Sandfeld Jensen Date: Tue, 2 Apr 2019 10:54:54 +0200 Subject: Replace Q_DECL_NOEXCEPT with noexcept in corelib In preparation of Qt6 move away from pre-C++11 macros. Change-Id: I44126693c20c18eca5620caab4f7e746218e0ce3 Reviewed-by: Thiago Macieira --- src/corelib/tools/qcollator.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/corelib/tools/qcollator.h') diff --git a/src/corelib/tools/qcollator.h b/src/corelib/tools/qcollator.h index 700de739bb..6c76ef038f 100644 --- a/src/corelib/tools/qcollator.h +++ b/src/corelib/tools/qcollator.h @@ -58,10 +58,10 @@ public: ~QCollatorSortKey(); QCollatorSortKey &operator=(const QCollatorSortKey &other); #ifdef Q_COMPILER_RVALUE_REFS - inline QCollatorSortKey &operator=(QCollatorSortKey &&other) Q_DECL_NOTHROW + inline QCollatorSortKey &operator=(QCollatorSortKey &&other) noexcept { swap(other); return *this; } #endif - void swap(QCollatorSortKey &other) Q_DECL_NOTHROW + void swap(QCollatorSortKey &other) noexcept { d.swap(other.d); } int compare(const QCollatorSortKey &key) const; @@ -88,13 +88,13 @@ public: ~QCollator(); QCollator &operator=(const QCollator &); #ifdef Q_COMPILER_RVALUE_REFS - QCollator(QCollator &&other) Q_DECL_NOTHROW + QCollator(QCollator &&other) noexcept : d(other.d) { other.d = nullptr; } - QCollator &operator=(QCollator &&other) Q_DECL_NOTHROW + QCollator &operator=(QCollator &&other) noexcept { swap(other); return *this; } #endif - void swap(QCollator &other) Q_DECL_NOTHROW + void swap(QCollator &other) noexcept { qSwap(d, other.d); } void setLocale(const QLocale &locale); -- cgit v1.2.3