git: initial import (.gitignore)
[evilwm.git] / list.h
blob041aea8b58e01be8eb1043c7f6aee5f52744d438
1 /* evilwm - Minimalist Window Manager for X
2 * Copyright (C) 1999-2009 Ciaran Anscomb <evilwm@6809.org.uk>
3 * see README for license and other details. */
5 #ifndef __LIST_H__
6 #define __LIST_H__
8 struct list {
9 struct list *next;
10 void *data;
13 /* Each of these return the new pointer to the head of the list: */
14 struct list *list_prepend(struct list *list, void *data);
15 struct list *list_append(struct list *list, void *data);
16 struct list *list_delete(struct list *list, void *data);
17 struct list *list_to_head(struct list *list, void *data);
18 struct list *list_to_tail(struct list *list, void *data);
20 /* Returns element in list: */
21 struct list *list_find(struct list *list, void *data);
23 #endif /* def __LIST_H__ */