summaryrefslogtreecommitdiff
path: root/src/02/04/list.h
blob: b04a2825c51e50930dacfeb2c8ecf23058ddd3f7 (plain)
1
2
3
4
5
6
7
8
9
10
11
typedef struct node {
  struct node *next;
  void *data;
} Node;

typedef void (*Printer)(void *);

Node *list_initialize(void *data);
Node *list_get(Node *from, int index);
Node *list_add(Node *head, void *data);
void list_inspect(Node *self, Printer printer);