Open CASCADE Technology 7.8.0
|
Implementation of FNV-1a with autodetect of sizeof(size_t). This function should work on unsigned char, otherwise it does not correctly implement the FNV-1a algorithm. The existing behaviour is retained for backwards compatibility. More...
Functions | |
uint32_t | FNVHash1A (const void *theKey, int theLen, uint32_t theSeed) |
uint64_t | FNVHash64A (const void *theKey, int theLen, uint64_t theSeed) |
template<typename T = size_t> | |
constexpr T | optimalSeed () |
Implementation of FNV-1a with autodetect of sizeof(size_t). This function should work on unsigned char, otherwise it does not correctly implement the FNV-1a algorithm. The existing behaviour is retained for backwards compatibility.
The default value for the seed is optimal for general cases at a certain hash size.