)]}'
{
  "commit": "04b6f927362867d6061aece738ba2c44615fa170",
  "tree": "7ceea17d9ae7242e37cc4b75b558e42e24cb2277",
  "parents": [
    "14af6bae5308dd9f690e74ba348786e50f069c47"
  ],
  "author": {
    "name": "Evan Brown CA",
    "email": "ezb@google.com",
    "time": "Wed Nov 18 12:05:11 2026 -0800"
  },
  "committer": {
    "name": "Copybara-Service",
    "email": "copybara-worker@google.com",
    "time": "Fri Nov 20 14:28:48 2026 -0800"
  },
  "message": "Preserve active reservation bounds across smaller reserve() calls and clear stale reservations on rehash(0)\n\nReserveTableToFitNewSize previously overwrote reservation_size_ with new_size and recomputed reserved_growth_ unconditionally as `new_size - size()`. Calling reserve(M) after reserve(N) (with `size() \u003c\u003d M \u003c N`) shrank both fields below the active N-element guarantee, causing sanitizer bug-detection rehashing to reallocate the backing array before N elements were inserted and causing `erase(begin(), end())` to restore reserved_growth_ to M instead of N. Calling reserve(M) with `M \u003c size()` also underflowed unsigned `M - size()`, setting reserved_growth_ to kReservedGrowthJustRanOut when `M \u003d\u003d size() - 1` (forcing an immediate rehash on the next insert) or wrapping it to a large positive count when `M \u003c\u003d size() - 2` (disabling iterator-invalidation generation increments on subsequent unreserved inserts).\n\nIn addition, Rehash(0) did not clear reserved_growth_ or reservation_size_ when shrinking or rehashing a previously reserved table, leaving stale reservation counts behind after capacity shrunk.\n\nUpdate ReserveTableToFitNewSize to advance reservation_size_ monotonically and keep `max(current_reserved_growth, new_size - size())` without unsigned underflow, and clear reserved_growth_ and reservation_size_ in Rehash when `n \u003d\u003d 0`.\n\nPiperOrigin-RevId: 1024871812\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "0a8e80fcb41c461bf7e53eb8740ed98480376c9f",
      "old_mode": 33188,
      "old_path": "absl/container/internal/raw_hash_set.cc",
      "new_id": "dd9c8c88480ea33f4ada8fa36b63fa6df1c05102",
      "new_mode": 33188,
      "new_path": "absl/container/internal/raw_hash_set.cc"
    },
    {
      "type": "modify",
      "old_id": "8f406375acfe14517aff6d48b2ac20ed59c296dd",
      "old_mode": 33188,
      "old_path": "absl/container/internal/raw_hash_set.h",
      "new_id": "368fbc36e267bd39152ebc032297d883430d550b",
      "new_mode": 33188,
      "new_path": "absl/container/internal/raw_hash_set.h"
    },
    {
      "type": "modify",
      "old_id": "970420e05f304b62ec84360c6d2c00e443fdfe76",
      "old_mode": 33188,
      "old_path": "absl/container/internal/raw_hash_set_test.cc",
      "new_id": "3bbeff03d818367dd183ee620e8f27cce5a7fbc8",
      "new_mode": 33188,
      "new_path": "absl/container/internal/raw_hash_set_test.cc"
    }
  ]
}
