ucx/list.h

Sat, 31 Dec 2011 18:04:28 +0100

author
Olaf Wintermann <olaf.wintermann@gmail.com>
date
Sat, 31 Dec 2011 18:04:28 +0100
changeset 6
50b5fe7c577f
parent 5
a1740117e2b7
child 9
013c5c4b7e44
permissions
-rw-r--r--

Fixed fatal super bug

olaf@2 1 /*
olaf@2 2 *
olaf@2 3 */
olaf@2 4
olaf@2 5 #ifndef LIST_H
olaf@2 6 #define LIST_H
olaf@2 7
olaf@6 8 #include "ucx.h"
olaf@6 9 #include <stddef.h>
olaf@6 10
olaf@2 11 #ifdef __cplusplus
olaf@2 12 extern "C" {
olaf@2 13 #endif
olaf@2 14
olaf@5 15 typedef struct UcxList UcxList;
olaf@5 16 struct UcxList {
olaf@5 17 void *data;
olaf@5 18 UcxList *next;
olaf@5 19 };
olaf@2 20
olaf@6 21 UcxList *ucx_list_append(UcxList *l, void *data);
olaf@6 22 UcxList *ucx_list_prepend(UcxList *l, void *data);
olaf@6 23 UcxList *ucx_list_concat(UcxList *l1, UcxDlist *l2);
olaf@6 24 UcxList *ucx_list_last(UcxList *l);
olaf@6 25 UcxList *ucx_list_get(UcxList *l, int index);
olaf@6 26 size_t ucx_list_size(UcxList *l);
olaf@6 27 void ucx_list_foreach(UcxList *l, ucx_callback fnc, void *data);
olaf@2 28
olaf@2 29
olaf@2 30 #ifdef __cplusplus
olaf@2 31 }
olaf@2 32 #endif
olaf@2 33
olaf@2 34 #endif /* LIST_H */
olaf@2 35

mercurial