aboutsummaryrefslogtreecommitdiff
path: root/lib/converters.h
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2019-11-02 16:20:57 +0900
committerKitsune Ral <Kitsune-Ral@users.sf.net>2019-11-02 16:20:57 +0900
commit2a7871cd9bc67a0bf311766a1edee2ff7a8e5355 (patch)
tree975404982395567202e59de32d87a7c3e8f0e90e /lib/converters.h
parentf82ad2a6196b7501bfe4138e2314f61180cde261 (diff)
downloadlibquotient-2a7871cd9bc67a0bf311766a1edee2ff7a8e5355.tar.gz
libquotient-2a7871cd9bc67a0bf311766a1edee2ff7a8e5355.zip
Compatibility with Qt 5.14
Diffstat (limited to 'lib/converters.h')
-rw-r--r--lib/converters.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/converters.h b/lib/converters.h
index 157bff27..075af7ef 100644
--- a/lib/converters.h
+++ b/lib/converters.h
@@ -30,6 +30,7 @@
#include <vector>
+#if QT_VERSION < QT_VERSION_CHECK(5,14,0)
// Enable std::unordered_map<QString, T>
// REMOVEME in favor of UnorderedMap, once we regenerate API files
namespace std {
@@ -37,15 +38,12 @@ template <>
struct hash<QString> {
size_t operator()(const QString& s) const Q_DECL_NOEXCEPT
{
- return qHash(s
-#if (QT_VERSION >= QT_VERSION_CHECK(5, 6, 0))
- ,
- uint(qGlobalQHashSeed())
-#endif
+ return qHash(s, uint(qGlobalQHashSeed())
);
}
};
} // namespace std
+#endif
class QVariant;