Browse Source

Added a small amount of test code

tree_alloc
Thomas Johnson 1 year ago
parent
commit
e0db3fb925
  1. 2
      Makefile
  2. 2
      main.c

2
Makefile

@ -1,7 +1,7 @@
objs = main.o tree_alloc.o util.o
CC = clang
COMMON_FLAGS = -std=c11
COMMON_FLAGS = -std=gnu11
OUT_NAME = the_alloc
dev: CFLAGS= $(COMMON_FLAGS) -g -D UNIT_TESTS

2
main.c

@ -26,5 +26,7 @@ int main() {
get_new_region,
error,
};
void *reg = alloc(&arena, 20, 4);
unalloc(&arena, reg);
return 0;
}
Loading…
Cancel
Save