Data Structures | Macros | Typedefs
queue.h File Reference
#include <stddef.h>
#include "nvim/func_attr.h"

Go to the source code of this file.

Data Structures

struct  _queue
 

Macros

#define QUEUE_DATA(ptr, type, field)   ((type *)((char *)(ptr) - offsetof(type, field)))
 
#define QUEUE_FOREACH(q, h, code)
 
#define QUEUE_HEAD(q)   (q)->next
 

Typedefs

typedef struct _queue QUEUE
 

Macro Definition Documentation

◆ QUEUE_DATA

#define QUEUE_DATA (   ptr,
  type,
  field 
)    ((type *)((char *)(ptr) - offsetof(type, field)))

◆ QUEUE_FOREACH

#define QUEUE_FOREACH (   q,
  h,
  code 
)
Value:
(q) = (h)->next; \
while ((q) != (h)) { \
QUEUE *next = q->next; \
code \
(q) = next; \
}

◆ QUEUE_HEAD

#define QUEUE_HEAD (   q)    (q)->next

Typedef Documentation

◆ QUEUE

typedef struct _queue QUEUE
next
m next
Definition: window.c:6850