diff -r 2842f729caab -r af766caea48d src/cx/list.h --- a/src/cx/list.h Sun Feb 14 11:31:13 2021 +0100 +++ b/src/cx/list.h Sun Feb 14 15:13:53 2021 +0100 @@ -32,7 +32,7 @@ #include #include "allocator.h" -typedef int(*CxListComparator)(void *left, void *right); +typedef int(*CxListComparator)(void const *left, void const *right); typedef struct { CxAllocator allocator; @@ -51,12 +51,12 @@ void *(*last)(cx_list *list); } cx_list_class; -struct cx_list_s { +typedef struct { cx_list_class *cl; cx_list data; -}; +} cx_list_s; -typedef struct cx_list_s *CxList; +typedef cx_list_s *CxList; int cxListAdd(CxList list, void *elem);