summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qdatetime.h
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2019-04-02 10:54:54 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2019-04-03 13:49:45 +0000
commita1e62e7ba14b00ac7c361936a18e7bc42bf1286d (patch)
tree50f5188dbc6092aca660eec970d71fe5ce1706ae /src/corelib/tools/qdatetime.h
parent6c761a0db11b7a2b0104dbf46607ca396ae7ee2d (diff)
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 <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/tools/qdatetime.h')
-rw-r--r--src/corelib/tools/qdatetime.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/corelib/tools/qdatetime.h b/src/corelib/tools/qdatetime.h
index 43271b34ed..144fb9b28a 100644
--- a/src/corelib/tools/qdatetime.h
+++ b/src/corelib/tools/qdatetime.h
@@ -266,16 +266,16 @@ public:
#if QT_CONFIG(timezone)
QDateTime(const QDate &date, const QTime &time, const QTimeZone &timeZone);
#endif // timezone
- QDateTime(const QDateTime &other) Q_DECL_NOTHROW;
- QDateTime(QDateTime &&other) Q_DECL_NOTHROW;
+ QDateTime(const QDateTime &other) noexcept;
+ QDateTime(QDateTime &&other) noexcept;
~QDateTime();
#ifdef Q_COMPILER_RVALUE_REFS
- QDateTime &operator=(QDateTime &&other) Q_DECL_NOTHROW { swap(other); return *this; }
+ QDateTime &operator=(QDateTime &&other) noexcept { swap(other); return *this; }
#endif
- QDateTime &operator=(const QDateTime &other) Q_DECL_NOTHROW;
+ QDateTime &operator=(const QDateTime &other) noexcept;
- void swap(QDateTime &other) Q_DECL_NOTHROW { qSwap(d.d, other.d.d); }
+ void swap(QDateTime &other) noexcept { qSwap(d.d, other.d.d); }
bool isNull() const;
bool isValid() const;
@@ -366,8 +366,8 @@ public:
static QDateTime fromSecsSinceEpoch(qint64 secs, const QTimeZone &timeZone);
#endif
- static qint64 currentMSecsSinceEpoch() Q_DECL_NOTHROW;
- static qint64 currentSecsSinceEpoch() Q_DECL_NOTHROW;
+ static qint64 currentMSecsSinceEpoch() noexcept;
+ static qint64 currentSecsSinceEpoch() noexcept;
#if defined(Q_OS_DARWIN) || defined(Q_QDOC)
static QDateTime fromCFDate(CFDateRef date);
@@ -410,8 +410,8 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QDateTime &);
// QDateTime is not noexcept for now -- to be revised once
// timezone and calendaring support is added
Q_CORE_EXPORT uint qHash(const QDateTime &key, uint seed = 0);
-Q_CORE_EXPORT uint qHash(const QDate &key, uint seed = 0) Q_DECL_NOTHROW;
-Q_CORE_EXPORT uint qHash(const QTime &key, uint seed = 0) Q_DECL_NOTHROW;
+Q_CORE_EXPORT uint qHash(const QDate &key, uint seed = 0) noexcept;
+Q_CORE_EXPORT uint qHash(const QTime &key, uint seed = 0) noexcept;
QT_END_NAMESPACE