mirror-chatterino2/src/util/QStringHash.hpp

19 lines
267 B
C++
Raw Normal View History

#pragma once
#include <QHash>
#include <QString>
namespace std {
2019-10-03 10:07:14 +02:00
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
template <>
struct hash<QString> {
std::size_t operator()(const QString &s) const
{
return qHash(s);
}
};
2019-10-03 10:07:14 +02:00
#endif
} // namespace std