# std.mem.Allocator: add return_address to the interface · gitcafe/zig

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

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

Visibility: public

Requested revision: cd6cdd0a752ba3e134ba371246cc02b1d7faaa88

Requested commit: cd6cdd0a752ba3e134ba371246cc02b1d7faaa88

Commit: cd6cdd0a752ba3e134ba371246cc02b1d7faaa88

Tree: e4b6aaa5a1d47466addf16fc1b60a9b40cb98bf8

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
std.mem.Allocator: add return_address to the interface

The high level Allocator interface API functions will now do a
`@returnAddress()` so that stack traces captured by allocator
implementations have a return address that does not include the
Allocator overhead functions. This makes `4` a more reasonable default
for how many stack frames to capture.

```

## Parents

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

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