mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-07 14:24:43 +00:00
1. When the arena is already empty, resetting with `retain_capacity` no longer
results in allocating a buffer with zero capacity.
This behavior was previously intended by the `(current_capacity == 0)` check,
but wasn't correctly implemented.
2. Resetting with `.{ .retain_with_limit = 0 }` is now equivalent to
`free_all` and a new buffer with zero capacity is no longer created.
This is a useful side-effect of the above fixes.
|
||
|---|---|---|
| .. | ||
| arena_allocator.zig | ||
| general_purpose_allocator.zig | ||
| log_to_writer_allocator.zig | ||
| logging_allocator.zig | ||
| memory_pool.zig | ||
| PageAllocator.zig | ||
| ThreadSafeAllocator.zig | ||
| WasmAllocator.zig | ||
| WasmPageAllocator.zig | ||