2 * collectn.c - implements variable length pointer arrays [collections].
4 * This file is public domain.
10 void collection_init(Collection
* c
)
14 for (i
= 0; i
< 32; i
++)
19 void **colln(Collection
* c
, int index
)
23 if (c
->next
== NULL
) {
24 c
->next
= malloc(sizeof(Collection
));
25 collection_init(c
->next
);
29 return &(c
->p
[index
]);
32 void collection_reset(Collection
* c
)
37 collection_reset(c
->next
);
42 for (i
= 0; i
< 32; i
++)