Gromacs
2026.0-dev-20241204-d69d709
|
Classes | |
struct | HashAnArray |
Functor for hashing an array of N bytes. More... | |
Functions | |
size_t | hashCombine (size_t seed, std::byte c) |
Unnecessarily declare the function below, to keep nvcc and clang-tidy happy simultaneously. More... | |
size_t anonymous_namespace device_management_common anonymous_namespace{device_management_common.cpp}::cpp::hashCombine | ( | const size_t | seed, |
std::byte | c | ||
) |
Unnecessarily declare the function below, to keep nvcc and clang-tidy happy simultaneously.
Combine seed
with c
to produce a combined hash.
The resulting seed is suitable to pass to a future call to this function.
Implementation is like that of Boost 1.33. It has been superseded in Boost, but its simplicity is enough for this use case. The hexadecimal constant is an arbitrary non-zero value, which avoids producing zero when all inputs were zero.