mcchunktools
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
Data Structures | Macros
list.h File Reference
#include <stddef.h>
Include dependency graph for list.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  list_head
 

Macros

#define INIT_LIST_HEAD(head)   (head)->flink = (head)->blink = (head)
 
#define list_empty(head)   ((head)->flink == (head))
 
#define list_entry(ptr, type, member)   ((type*)((char*)(ptr) - offsetof(type, member)))
 
#define list_for_each(pos, head)
 
#define list_for_each_reverse(pos, head)
 
#define list_for_each_safe(pos, n, head)
 
#define list_for_each_reverse_safe(pos, p, head)
 

Macro Definition Documentation

#define INIT_LIST_HEAD (   head)    (head)->flink = (head)->blink = (head)

Definition at line 16 of file list.h.

#define list_empty (   head)    ((head)->flink == (head))

Definition at line 57 of file list.h.

#define list_entry (   ptr,
  type,
  member 
)    ((type*)((char*)(ptr) - offsetof(type, member)))

Definition at line 60 of file list.h.

#define list_for_each (   pos,
  head 
)
Value:
for((pos) = (head)->flink; \
(pos) != (head); \
(pos) = (pos)->flink)

Definition at line 67 of file list.h.

#define list_for_each_reverse (   pos,
  head 
)
Value:
for((pos) = (head)->blink; \
(pos) != (head); \
(pos) = (pos)->blink)

Definition at line 73 of file list.h.

#define list_for_each_reverse_safe (   pos,
  p,
  head 
)
Value:
for((pos) = (head)->blink, (p) = (pos)->blink; \
(pos) != (head); \
(pos) = (p), (p) = (pos)->blink)

Definition at line 91 of file list.h.

#define list_for_each_safe (   pos,
  n,
  head 
)
Value:
for((pos) = (head)->flink, (n) = (pos)->flink; \
(pos) != (head); \
(pos) = (n), (n) = (pos)->flink)

Definition at line 85 of file list.h.