In #53804, I fixed the most immediate problem arising from how HashMap handles the empty table, but @gnzlbg still (rightly) sees more problems. We still use 1 instead of NonNull::dangling() as value for EMPTY, and ptr() even tests equality with EMPTY to return NULL instead. We can't really use non-NULL pointers as sentinel values like that, and NULL is often a worse choice than an aligned dangling pointer because the latter are at least valid for zero-sized operations.
See here for @gnzlbg's suggestions.
In #53804, I fixed the most immediate problem arising from how
HashMaphandles the empty table, but @gnzlbg still (rightly) sees more problems. We still use1instead ofNonNull::dangling()as value forEMPTY, andptr()even tests equality withEMPTYto return NULL instead. We can't really use non-NULL pointers as sentinel values like that, and NULL is often a worse choice than an aligned dangling pointer because the latter are at least valid for zero-sized operations.See here for @gnzlbg's suggestions.