Lines Matching defs:elm
42 list_insert(struct list *list, struct list *elm)
46 assert(((elm->next == NULL && elm->prev == NULL) || list_empty(elm)) ||
47 !"elm->next|prev is not NULL, list node used twice?");
49 elm->prev = list;
50 elm->next = list->next;
51 list->next = elm;
52 elm->next->prev = elm;
56 list_append(struct list *list, struct list *elm)
60 assert(((elm->next == NULL && elm->prev == NULL) || list_empty(elm)) ||
61 !"elm->next|prev is not NULL, list node used twice?");
63 elm->next = list;
64 elm->prev = list->prev;
65 list->prev = elm;
66 elm->prev->next = elm;
70 list_remove(struct list *elm)
72 assert((elm->next != NULL && elm->prev != NULL) ||
75 elm->prev->next = elm->next;
76 elm->next->prev = elm->prev;
77 elm->next = NULL;
78 elm->prev = NULL;