Current code already assumes (correctly), that shrink() does not throw, otherwise we risk leaking memory allocated in get_ptr(): ``` ts_value_lru_entry* new_lru_entry = Alloc().template allocate_object<ts_value_lru_entry>(); // Remove the least recently used items if map is too big. shrink(); ``` Let's be explicit and mark shrink() and a few helper methods that it uses as noexcept. Ultimately they are all noexcept anyway, because polymorphic allocator's deallocation routines don't throw, and neither do boost intrusive list iterators. Closes #10565
32 KiB
32 KiB