diff --git a/src/corelib/tools/qhash.cpp b/src/corelib/tools/qhash.cpp index 65c88d35abc..928707660b4 100644 --- a/src/corelib/tools/qhash.cpp +++ b/src/corelib/tools/qhash.cpp @@ -802,7 +802,7 @@ uint qHash(long double key, uint seed) Q_DECL_NOTHROW } #endif -/*! \fn uint qHash(QChar key, uint seed = 0) +/*! \fn uint qHash(const QChar key, uint seed = 0) \relates QHash \since 5.0 diff --git a/src/corelib/tools/qhash.h b/src/corelib/tools/qhash.h index c09d7aaccbb..7a421a4586a 100644 --- a/src/corelib/tools/qhash.h +++ b/src/corelib/tools/qhash.h @@ -86,7 +86,7 @@ Q_CORE_EXPORT Q_DECL_CONST_FUNCTION uint qHash(double key, uint seed = 0) Q_DECL #ifndef Q_OS_DARWIN Q_CORE_EXPORT Q_DECL_CONST_FUNCTION uint qHash(long double key, uint seed = 0) Q_DECL_NOTHROW; #endif -Q_DECL_CONST_FUNCTION inline uint qHash(QChar key, uint seed = 0) Q_DECL_NOTHROW { return qHash(key.unicode(), seed); } +Q_DECL_CONST_FUNCTION Q_DECL_CONSTEXPR inline uint qHash(const QChar key, uint seed = 0) Q_DECL_NOTHROW { return qHash(key.unicode(), seed); } Q_CORE_EXPORT Q_DECL_PURE_FUNCTION uint qHash(const QByteArray &key, uint seed = 0) Q_DECL_NOTHROW; Q_CORE_EXPORT Q_DECL_PURE_FUNCTION uint qHash(const QString &key, uint seed = 0) Q_DECL_NOTHROW; Q_CORE_EXPORT Q_DECL_PURE_FUNCTION uint qHash(const QStringRef &key, uint seed = 0) Q_DECL_NOTHROW;