This commit is contained in:
taiyu 2015-08-31 08:34:14 -07:00
parent 7dcca7a4b4
commit d11f3b8f64

View file

@ -19,7 +19,7 @@ void list_cat(list_t *list, list_t *source);
// ITEM will be NULL after empty list
#define list_for(ITEM, LIST) \
ITEM = LIST->length ? LIST->items[0] : NULL; \
for(int list_it = 0, list_len = LIST->length; \
for (int list_it = 0, list_len = LIST->length; \
list_it < list_len; \
ITEM = LIST->items[++list_it])