eval: lookup rule map building; eval: use general 'set' type-kind to specify custom lookup rule; watch: new table <-> stable-point mappings

This commit is contained in:
Ryan Fleury
2025-01-30 10:57:29 -08:00
parent 394d35287a
commit 92e68701d0
6 changed files with 96 additions and 17 deletions
+7 -5
View File
@@ -9,14 +9,16 @@
////////////////////////////////
//~ rjf: Basic Helper Functions
#if !defined(XXH_IMPLEMENTATION)
# define XXH_IMPLEMENTATION
# define XXH_STATIC_LINKING_ONLY
# include "third_party/xxHash/xxhash.h"
#endif
internal U64
e_hash_from_string(U64 seed, String8 string)
{
U64 result = seed;
for(U64 i = 0; i < string.size; i += 1)
{
result = ((result << 5) + result) + string.str[i];
}
U64 result = XXH3_64bits_withSeed(string.str, string.size, seed);
return result;
}