- // I use the same hash function as for 32-bit signed integers. This
- // probably will not have great performance for values that don't fit
- // into a 32-bit signed int, but this will do for now
- int key32 = (int)(*key);
- return dict_hash_int(&key32);
+ int const a = (int) *key;
+ int const b = (int) (*key >> 32);
+ return dict_hash_int (&a) ^ dict_hash_int (&b);