1.1 --- a/src/cx/linked_list.h Sun Feb 07 21:29:51 2021 +0100 1.2 +++ b/src/cx/linked_list.h Mon Feb 08 00:14:07 2021 +0100 1.3 @@ -34,10 +34,22 @@ 1.4 1.5 void *cx_linked_list_last(void **begin, void **end, ptrdiff_t loc_next); 1.6 1.7 -int cx_linked_list_add(void **begin, void **end, ptrdiff_t loc_prev, ptrdiff_t loc_next, void *newnode); 1.8 - 1.9 -CxList cxLinkedListCreate(CxAllocator allocator, CxListComparator comparator, size_t itemsize); 1.10 +int cx_linked_list_add(void **begin, void **end, ptrdiff_t loc_prev, ptrdiff_t loc_next, void *new_node); 1.11 1.12 extern cx_list_class cx_linked_list_class; 1.13 1.14 +typedef struct { 1.15 + void **begin; 1.16 + void **end; 1.17 + ptrdiff_t loc_prev; 1.18 + ptrdiff_t loc_next; 1.19 + size_t item_size; 1.20 +} CxLinkedListDesc; 1.21 + 1.22 +CxList cxLinkedListCreate(CxAllocator allocator, CxListComparator comparator, size_t item_size); 1.23 + 1.24 +CxList cxLinkedListWrap(CxAllocator allocator, CxListComparator comparator, CxLinkedListDesc desc); 1.25 + 1.26 +size_t cxLinkedListRecalculateSize(CxList list); 1.27 + 1.28 #endif /* UCX_LINKED_LIST_H */