diff --git a/src/arena_allocator.hpp b/src/arena_allocator.hpp index 41f462b..a51be67 100644 --- a/src/arena_allocator.hpp +++ b/src/arena_allocator.hpp @@ -237,6 +237,10 @@ public: * - The old pointer becomes invalid if a copy occurs * - Like malloc/realloc, the contents beyond old_size are uninitialized * - When copying to new location, uses the specified alignment + * - **Shrinking behavior**: If `new_size < old_size` and the allocation + * is *not* the most recent one, this function returns the original + * pointer, but **no memory is reclaimed**. The arena design does not + * support freeing memory from the middle of a block. */ void *realloc_raw(void *ptr, uint32_t old_size, uint32_t new_size, uint32_t alignment = alignof(std::max_align_t));