Improve modularity, introduce arena_create()
This commit is contained in:
5
test.c
5
test.c
@@ -2,13 +2,12 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
#ifdef DEBUG
|
||||
#define malloc(n) (printf("%s:%d:%s: malloc(%ld)\n",\
|
||||
__FILE__, __LINE__, __func__, (n)), malloc((n)));
|
||||
#define realloc(p, s) (printf("%s:%d:%s: realloc(%p, %lu)\n",\
|
||||
__FILE__, __LINE__, __func__, (p), (s)), realloc((p), (s)));
|
||||
#define free(p) (printf("%s:%d:%s: free(%p)\n",\
|
||||
__FILE__, __LINE__, __func__, (p)), free((p)));
|
||||
#endif // DEBUG
|
||||
|
||||
#define ARENA_MIN_CAPACITY 400
|
||||
#define ARENA_IMPLEMENTATION
|
||||
#include "arena.h"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user