Skip to content

Commit

Permalink
Fix qt < 5.14 build
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Sep 14, 2021
1 parent 75c7b28 commit 453e2eb
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/core/qgis.h
Expand Up @@ -1225,6 +1225,20 @@ namespace qgis
#endif
}
}

#if QT_VERSION < QT_VERSION_CHECK(5, 14, 0)
namespace std
{
template<> struct hash<QString>
{
std::size_t operator()( const QString &s ) const noexcept
{
return ( size_t ) qHash( s );
}
};
}
#endif

///@endcond
#endif

Expand Down

0 comments on commit 453e2eb

Please sign in to comment.