#include <cstddef>
#include <functional>
Go to the source code of this file.
|
| template<class T > |
| constexpr size_t | qx::get_hash (const T &value) noexcept |
| | Get an object hash. More...
|
| |
| template<class T > |
| constexpr void | qx::hash_combine (size_t &seed, const T &value) noexcept |
| | Combine hashes. More...
|
| |
- Author
- Khrapov
- Date
- 18.08.2025
- Copyright
- (c) Nick Khrapov, 2025. All right reserved.
Definition in file hash.h.
◆ get_hash()
template<class T >
| constexpr size_t qx::get_hash |
( |
const T & |
value | ) |
|
|
constexprnoexcept |
Get an object hash.
A simple wrapper over std::hash that removes the need to specify the type and unnecessary parentheses.
- Template Parameters
-
- Parameters
-
- Return values
-
Definition at line 26 of file hash.h.
◆ hash_combine()
template<class T >
| constexpr void qx::hash_combine |
( |
size_t & |
seed, |
|
|
const T & |
value |
|
) |
| |
|
constexprnoexcept |
Combine hashes.
- Template Parameters
-
- Parameters
-
| seed | - input/output hash value |
| value | - object to hash |
Definition at line 38 of file hash.h.