diff options
Diffstat (limited to 'mempool/include')
| -rw-r--r-- | mempool/include/mempool.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mempool/include/mempool.h b/mempool/include/mempool.h index 0de7ac6..ad25614 100644 --- a/mempool/include/mempool.h +++ b/mempool/include/mempool.h | |||
| @@ -69,7 +69,8 @@ | |||
| 69 | /// (default) or gracefully return null. Call mem_enable_traps() to toggle this | 69 | /// (default) or gracefully return null. Call mem_enable_traps() to toggle this |
| 70 | /// behaviour. | 70 | /// behaviour. |
| 71 | /// New blocks are conveniently zeroed out. | 71 | /// New blocks are conveniently zeroed out. |
| 72 | #define mempool_alloc(POOL) mempool_alloc_(&(POOL)->pool) | 72 | #define mempool_alloc(POOL) \ |
| 73 | (__typeof__((POOL)->object[0])*)mempool_alloc_(&(POOL)->pool) | ||
| 73 | 74 | ||
| 74 | /// Free the block. | 75 | /// Free the block. |
| 75 | /// The block pointer is conveniently set to null. | 76 | /// The block pointer is conveniently set to null. |
