diff options
author | Dimitri Staessens <dimitri.staessens@intec.ugent.be> | 2016-03-11 17:30:45 +0100 |
---|---|---|
committer | Dimitri Staessens <dimitri.staessens@intec.ugent.be> | 2016-03-11 17:30:45 +0100 |
commit | d6897a45d8b45d5bc00f1a6dcd627a14aa535120 (patch) | |
tree | e37582961e744a7d56e29c134ba147df2da1a061 /include/ouroboros/list.h | |
parent | b68c90fbf9f4a60e4fc406903e38d20453ba8253 (diff) | |
parent | 328078c1ee01d64733328b3dad3e7db68dcd6d2d (diff) | |
download | ouroboros-d6897a45d8b45d5bc00f1a6dcd627a14aa535120.tar.gz ouroboros-d6897a45d8b45d5bc00f1a6dcd627a14aa535120.zip |
Merged in sandervrijders/ouroboros/be-irmd (pull request #26)
Helper functions for naming and extension of the irmd code
Diffstat (limited to 'include/ouroboros/list.h')
-rw-r--r-- | include/ouroboros/list.h | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/include/ouroboros/list.h b/include/ouroboros/list.h index 1a96ddb4..f446749d 100644 --- a/include/ouroboros/list.h +++ b/include/ouroboros/list.h @@ -241,30 +241,4 @@ void list_splice_init(struct list_head * list, for (pos = (head)->next, n = pos->next; pos != (head); \ pos = n, n = pos->next) -/** - * list_for_each_entry - iterate over list of given type - * @pos: the type * to use as a loop counter. - * @head: the head for your list. - * @member: the name of the list_struct within the struct. - */ -#define list_for_each_entry(pos, head, member) \ - for (pos = list_entry((head)->next, typeof(*pos), member); \ - &pos->member != (head); \ - pos = list_entry(pos->member.next, typeof(*pos), member)) - -/** - * list_for_each_entry_safe - iterate over list of given type safe - * against removal of list entry - * @pos: the type * to use as a loop counter. - * @n: another type * to use as temporary storage - * @head: the head for your list. - * @member: the name of the list_struct within the struct. - */ -#define list_for_each_entry_safe(pos, n, head, member) \ - for (pos = list_entry((head)->next, typeof(*pos), member), \ - n = list_entry(pos->member.next, typeof(*pos), member); \ - &pos->member != (head); \ - pos = n, n = list_entry(n->member.next, typeof(*n), member)) - - #endif |