# std.ArrayList: fix shrinkAndFree · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/16caea38d1fe0fb1ea7f18e6344f21f8c11d8dfe)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 16caea38d1fe0fb1ea7f18e6344f21f8c11d8dfe

Requested commit: 16caea38d1fe0fb1ea7f18e6344f21f8c11d8dfe

Commit: 16caea38d1fe0fb1ea7f18e6344f21f8c11d8dfe

Tree: 2b53170029ba95146d4def4a83ac60486c47e571

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
std.ArrayList: fix shrinkAndFree

Fixes a regression introduced in
e35f297aeb993ec956ae80379ddf7f86069e109b.

Now there is test coverage for ArrayList.shrinkAndFree in the case when
resizing fails.

```

## Parents

- [c84bc3a06b9a529d063518e6a4a331ba09227c8a](https://git.cafe/gitcafe/zig/commit/c84bc3a06b9a529d063518e6a4a331ba09227c8a?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/16caea38d1fe0fb1ea7f18e6344f21f8c11d8dfe?format=markdown)
