Update README.md
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
# arena.h
|
||||
|
||||
A single header library that implements
|
||||
[region-based memory management](https://en.wikipedia.org/wiki/Region-based_memory_management) in C.
|
||||
[region-based memory management](https://en.wikipedia.org/wiki/Region-based_memory_management)
|
||||
in C using a linked list approach.
|
||||
|
||||
## Example
|
||||
|
||||
@@ -11,7 +12,7 @@ A single header library that implements
|
||||
|
||||
int main(void)
|
||||
{
|
||||
Arena a = {0};
|
||||
Arena a = {0}; // or arena_create(...) to specify the region capacity
|
||||
|
||||
int *x = arena_alloc(&a, sizeof(*x) * 69);
|
||||
float *y = arena_alloc(&a, sizeof(*y) * 420);
|
||||
|
||||
Reference in New Issue
Block a user