diff options
| author | Thomas Schmucker <ts@its1.de> | 2026-06-21 17:12:55 +0200 |
|---|---|---|
| committer | Thomas Schmucker <ts@its1.de> | 2026-06-21 17:12:55 +0200 |
| commit | f67c54eb50b488ecd2e92ae4c495e89bd3da5663 (patch) | |
| tree | f452270f69a727f7c515ff9c00c4022e0758a5a5 /src/allocator.h | |
| parent | c353b1a162065e4efb7da30d8e57631654ebd6fc (diff) | |
| download | data-structures-master.tar.gz data-structures-master.tar.bz2 data-structures-master.zip | |
Diffstat (limited to 'src/allocator.h')
| -rw-r--r-- | src/allocator.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/allocator.h b/src/allocator.h index dd9bb16..2c0c5b9 100644 --- a/src/allocator.h +++ b/src/allocator.h | |||
| @@ -3,6 +3,9 @@ | |||
| 3 | #include <stddef.h> /* size_t */ | 3 | #include <stddef.h> /* size_t */ |
| 4 | 4 | ||
| 5 | struct allocator { | 5 | struct allocator { |
| 6 | #ifndef NDEBUG | ||
| 7 | struct allocator *self; | ||
| 8 | #endif | ||
| 6 | void *(*allocate)(struct allocator *allocator, size_t n); | 9 | void *(*allocate)(struct allocator *allocator, size_t n); |
| 7 | void (*deallocate)(struct allocator *allocator, void *ptr); | 10 | void (*deallocate)(struct allocator *allocator, void *ptr); |
| 8 | }; | 11 | }; |
