Clojure cards are a custom implementation that is constant and immutable (i.e., it does not use Java hash files, which would not provide sufficient performance when used in an immutable data structure).
It uses 32-bit hash codes, hence 2 ^ 32 possible hash codes . In case of collisions, keys and values ββare stored in an array for each hash bucket, so it is possible to have more than 2 ^ 32 keys . See PersistentHashMap source - in particular, the internal HashCollisionNode class is used to store a bucket of keys / values ββat a single hash code value.
Since the number of possible hash codes is fixed, consistent hashing does not matter - the key never needs to be reassigned.
See also:
source share