mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-26 14:28:30 +00:00
Make minor improvements
This commit is contained in:
parent
04caf6f9ad
commit
95b142e4e5
95 changed files with 3818 additions and 2760 deletions
3
third_party/chibicc/hashmap.c
vendored
3
third_party/chibicc/hashmap.c
vendored
|
@ -35,8 +35,9 @@ static void rehash(HashMap *map) {
|
|||
map2.capacity = cap;
|
||||
for (int i = 0; i < map->capacity; i++) {
|
||||
HashEntry *ent = &map->buckets[i];
|
||||
if (ent->key && ent->key != TOMBSTONE)
|
||||
if (ent->key && ent->key != TOMBSTONE) {
|
||||
hashmap_put2(&map2, ent->key, ent->keylen, ent->val);
|
||||
}
|
||||
}
|
||||
assert(map2.used == nkeys);
|
||||
*map = map2;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue