diff options
| author | Tyge Løvset <[email protected]> | 2021-11-08 18:18:42 +0100 |
|---|---|---|
| committer | Tyge Løvset <[email protected]> | 2021-11-08 18:18:42 +0100 |
| commit | 02dfa9735234fd2676ce260e0ba4bc26e3e8b12f (patch) | |
| tree | f27764119b88eed1cd90a418d5cd9b83be4e5af9 /include/stc/cmap.h | |
| parent | c8278d5437ac51ce1d63327fee6296035d80fe20 (diff) | |
| download | STC-modified-02dfa9735234fd2676ce260e0ba4bc26e3e8b12f.tar.gz STC-modified-02dfa9735234fd2676ce260e0ba4bc26e3e8b12f.zip | |
Changed default_hash() and c_strhash()
Diffstat (limited to 'include/stc/cmap.h')
| -rw-r--r-- | include/stc/cmap.h | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/include/stc/cmap.h b/include/stc/cmap.h index 883fec03..2d0a81f7 100644 --- a/include/stc/cmap.h +++ b/include/stc/cmap.h @@ -221,13 +221,6 @@ _cx_memb(_erase_at)(_cx_self* self, _cx_iter it) { #if !defined(STC_HEADER) || defined(STC_IMPLEMENTATION) || defined(i_imp)
#ifndef CMAP_H_INCLUDED
-STC_INLINE uint64_t c_default_hash(const void *key, size_t len) {
- const char* str = (const char*)key, *e = str + len;
- uint64_t h = 0xb5ad4eceda1ce2a9;
- while (str != e) h = (_c_rotl(h, 4) ^ (h << 13)) + *str++;
- return h ^ (h >> 15);
-}
-
//STC_INLINE size_t fastrange_uint64_t(uint64_t x, uint64_t n)
// { uint64_t lo, hi; c_umul128(x, n, &lo, &hi); return hi; }
#define fastrange_uint32_t(x, n) (uint32_t)((uint32_t)(x)*(uint64_t)(n) >> 32)
|
