qt5base-lts/tests/auto/corelib/tools/qhash
Giuseppe D'Angelo 81e893fb2d QHash: support std::hash as hashing function
In addition (and as a fallback) from requiring qHash, add support
for std::hash specializations. This catches two birds with one stone:

1) users of Qt can simply specialize std::hash for their datatypes,
and use them in both QHash and stdlib unordered associative containers;

2) we get QHash support for any (stdlib) datatype that is hashable
without having to overload qHash for them.

[ChangeLog][QtCore][QHash] QHash, QMultiHash and QSet now support
for key types anything that can be hashed via std::hash, instead of
always requiring a qHash() overload.

Change-Id: Ib5ecba86e4b376d318389500bd24883ac6534c5f
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
2020-11-30 17:16:22 +01:00
..
.gitignore Moving relevant tests to corelib/tools 2011-09-01 13:07:23 +02:00
.prev_CMakeLists.txt CMake: Regenerate projects to use new qt_internal_ API 2020-09-23 16:59:06 +02:00
CMakeLists.txt CMake: Regenerate projects to use new qt_internal_ API 2020-09-23 16:59:06 +02:00
qhash.pro Add QT_NO_JAVA_STYLE_ITERATORS and mark QtBase free of it 2019-07-03 14:48:37 +02:00
tst_qhash.cpp QHash: support std::hash as hashing function 2020-11-30 17:16:22 +01:00