summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2015-04-30 10:23:58 +0200
committerMarc Mutz <marc.mutz@kdab.com>2015-05-19 05:16:24 +0000
commit009b11c30086f2ab40d3e86691f34cad31999a8f (patch)
tree4e2a9fd1a8f17bcc43c5fc8db9399f47e1831432
parent412eb090c9b7d17a3f5b0fbc0f3aebdce70a443b (diff)
downloadqtbase-009b11c30086f2ab40d3e86691f34cad31999a8f.tar.gz
QStateMachine: fix RestorableId exception specification
We're interested in whether qHash(QByteArray) throws, not declval<QByteArray>, of course. Change-Id: If3ba6e90aba69d0d4d12ac289e817f0d9705a601 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
-rw-r--r--src/corelib/statemachine/qstatemachine_p.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/corelib/statemachine/qstatemachine_p.h b/src/corelib/statemachine/qstatemachine_p.h
index 5db6489fa9..426f2732df 100644
--- a/src/corelib/statemachine/qstatemachine_p.h
+++ b/src/corelib/statemachine/qstatemachine_p.h
@@ -210,7 +210,8 @@ public:
QObject *obj;
QByteArray prop;
// two overloads because friends can't have default arguments
- friend uint qHash(const RestorableId &key, uint seed) Q_DECL_NOEXCEPT_EXPR(noexcept(std::declval<QByteArray>()))
+ friend uint qHash(const RestorableId &key, uint seed)
+ Q_DECL_NOEXCEPT_EXPR(noexcept(qHash(std::declval<QByteArray>())))
{ return qHash(qMakePair(key.obj, key.prop), seed); }
friend uint qHash(const RestorableId &key) Q_DECL_NOEXCEPT_EXPR(noexcept(qHash(key, 0U)))
{ return qHash(key, 0U); }