1.1 --- a/src/cx/linked_list.h Tue Mar 28 19:13:33 2023 +0200 1.2 +++ b/src/cx/linked_list.h Tue Mar 28 21:00:33 2023 +0200 1.3 @@ -58,7 +58,9 @@ 1.4 * cxListStorePointers() was called immediately after creation. 1.5 * 1.6 * @param allocator the allocator for allocating the list nodes 1.7 + * (if \c NULL the cxDefaultAllocator will be used) 1.8 * @param comparator the comparator for the elements 1.9 + * (if \c NULL sort and find functions will not work) 1.10 * @param item_size the size of each element in bytes 1.11 * @return the created list 1.12 */ 1.13 @@ -66,7 +68,7 @@ 1.14 CxAllocator const *allocator, 1.15 CxListComparator comparator, 1.16 size_t item_size 1.17 -) __attribute__((__nonnull__)); 1.18 +); 1.19 1.20 /** 1.21 * Allocates a linked list for storing elements with \p item_size bytes each. 1.22 @@ -81,7 +83,8 @@ 1.23 * @param item_size the size of each element in bytes 1.24 * @return the created list 1.25 */ 1.26 -CxList *cxLinkedListCreateSimple(size_t item_size); 1.27 +#define cxLinkedListCreateSimple(item_size) \ 1.28 + cxLinkedListCreate(NULL, NULL, item_size) 1.29 1.30 /** 1.31 * Finds the node at a certain index.