+ // make sure we actually changing the size
+ if (nb != num_buckets) {
+ fprintf(stderr, "Resizing from %d to %d buckets\n", (int)num_buckets, nb);
+ num_buckets = nb;
+ delete[] buckets;
+ hash_mask = num_buckets-1;
+
+ buckets = new hash_bucket[num_buckets];
+ total_memory = num_buckets * sizeof(hash_bucket);
+ }