diff options
author | Liang Qi <liang.qi@qt.io> | 2016-06-10 23:27:10 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@qt.io> | 2016-06-10 23:27:10 +0200 |
commit | cbe332405aa22257d432f1797b325f5e57007c20 (patch) | |
tree | 0d817dc7ed2f3a2f6035f924a824d351420910c5 /src/corelib/json | |
parent | d2c6294bd5cc3c2e61aaa0c83bfd74941ced150e (diff) | |
parent | 67ca72796e23269451795baf9adde02a184a7b9e (diff) | |
download | qtbase-cbe332405aa22257d432f1797b325f5e57007c20.tar.gz |
Merge remote-tracking branch 'origin/5.6' into 5.7
Conflicts:
configure
mkspecs/macx-ios-clang/features/default_pre.prf
mkspecs/macx-ios-clang/features/sdk.prf
mkspecs/unsupported/freebsd-g++46/qplatformdefs.h
src/widgets/styles/qgtkstyle.cpp
tests/auto/corelib/io/qdiriterator/qdiriterator.pro
tests/auto/corelib/io/qfileinfo/qfileinfo.pro
Change-Id: Ia943555d1e59234a66f7dc65bdfda838e40001b5
Diffstat (limited to 'src/corelib/json')
-rw-r--r-- | src/corelib/json/qjson_p.h | 2 | ||||
-rw-r--r-- | src/corelib/json/qjsonobject.cpp | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/corelib/json/qjson_p.h b/src/corelib/json/qjson_p.h index f92a6821d7..b0a634cb4a 100644 --- a/src/corelib/json/qjson_p.h +++ b/src/corelib/json/qjson_p.h @@ -684,6 +684,8 @@ public: bool operator >=(const Entry &other) const; }; +inline bool operator!=(const Entry &lhs, const Entry &rhs) { return !(lhs == rhs); } + inline bool Entry::operator >=(const QString &key) const { if (value.latinKey) diff --git a/src/corelib/json/qjsonobject.cpp b/src/corelib/json/qjsonobject.cpp index b5b6f36bc6..fb651f0f24 100644 --- a/src/corelib/json/qjsonobject.cpp +++ b/src/corelib/json/qjsonobject.cpp @@ -599,8 +599,8 @@ bool QJsonObject::operator==(const QJsonObject &other) const for (uint i = 0; i < o->length; ++i) { QJsonPrivate::Entry *e = o->entryAt(i); - QJsonValue v(d, o, e->value); - if (other.value(e->key()) != v) + QJsonPrivate::Entry *oe = other.o->entryAt(i); + if (*e != *oe || QJsonValue(d, o, e->value) != QJsonValue(other.d, other.o, oe->value)) return false; } |