Yet another try to get 0.51.2-pre2 in cvs
[wmaker-crm.git] / WINGs / llist.h
blobd956ae55af183e58537bc5bd94cadcd3db8b9916
3 #if defined(__GNUC__) && !defined(__STRICT_ANSI__)
4 # define WINLINE inline
5 #else
6 # define WINLINE
7 #endif
9 typedef struct list_t {
10 void *head;
11 struct list_t *tail;
12 } list_t;
15 WINLINE void *lhead(list_t *list);
18 WINLINE list_t *ltail(list_t *list);
21 WINLINE list_t *lcons(void *newHead, list_t *list);
24 WINLINE list_t *lappend(list_t *list, list_t *tail);
27 WINLINE void lfree(list_t *list);
30 WINLINE void *lfind(void *object, list_t *list, int (*compare)(void*, void*));
33 WINLINE int llength(list_t *list);
36 WINLINE list_t *lremove(list_t *list, void *object);
39 WINLINE list_t *lremovehead(list_t *list);