*/
CxList *cxLinkedListCreate(
CxAllocator const *allocator,
- CxListComparator comparator,
+ cx_compare_func comparator,
size_t item_size
);
* @param loc_data the location of the \c data pointer within your node struct
* @param cmp_func a compare function to compare \p elem against the node data
* @param elem a pointer to the element to find
- * @return the index of the element or a past-one index if the element could not be found
+ * @return the index of the element or a negative value if it could not be found
*/
-size_t cx_linked_list_find(
+ssize_t cx_linked_list_find(
void const *start,
ptrdiff_t loc_advance,
ptrdiff_t loc_data,
- CxListComparator cmp_func,
+ cx_compare_func cmp_func,
void const *elem
) __attribute__((__nonnull__));
ptrdiff_t loc_prev,
ptrdiff_t loc_next,
ptrdiff_t loc_data,
- CxListComparator cmp_func
+ cx_compare_func cmp_func
) __attribute__((__nonnull__(1, 6)));
void const *begin_right,
ptrdiff_t loc_advance,
ptrdiff_t loc_data,
- CxListComparator cmp_func
+ cx_compare_func cmp_func
) __attribute__((__nonnull__(5)));
/**