Loading...
Searching...
No Matches
Go to the documentation of this file.
14#define MetaScopedExpr(Pre_, Post_, ScopedExpr_) \
32#define LIST_FOR_EACH(_head, _struct_type, _var) _LIST_FOR_EACH(_head, _struct_type, Link, _var)
33#define LIST_FOR_NEXT(_start, _head, _type, _var) _LIST_FOR_NEXT(_start, _head, _type, Link, _var)
34#define LIST_FOR_EACH_LINK(_head, _struct_type, _member, _var) _LIST_FOR_EACH(_head, _struct_type, _member, _var)
39#define HANDLE_TO_UINT32(_var) (UINT32)((UINT64)_var & 0xffffffff)
40#define PVOID_TO_BOOLEAN(_var) (BOOLEAN)((UINT64)_var & 0xff)
45#define _NEXT(_var, _member) _var->_member.Flink
46#define _NEXT_ENTRY(_var, _member, _type) CONTAINING_RECORD(_NEXT(_var, _member), _type, _member)
48#define PREPROC_CONCAT(a, b) PREPROC_CONCAT_1(a, b)
49#define PREPROC_CONCAT_1(a, b) PREPROC_CONCAT_2(~, a##b)
50#define PREPROC_CONCAT_2(p, res) res
52#define UNIQUE_NAME(base) PREPROC_CONCAT(base, __LINE__)
54#define _LIST_FOR_EACH(_head, _type, _member, _var) \
55 for (_type * _var = CONTAINING_RECORD(_head.Flink, _type, _member), *UNIQUE_NAME(_n) = _NEXT_ENTRY(_var, _member, _type); \
56 &_var->_member != &_head; \
57 _var = UNIQUE_NAME(_n), UNIQUE_NAME(_n) = _NEXT_ENTRY(_var, _member, _type))
59#define _LIST_FOR_NEXT(_start, _head, _type, _member, _var) \
60 for (_type * _var = _NEXT_ENTRY(_start, _member, _type), *UNIQUE_NAME(_n) = _NEXT_ENTRY(_var, _member, _type); \
61 &_var->_member != &_head; \
62 _var = UNIQUE_NAME(_n), UNIQUE_NAME(_n) = _NEXT_ENTRY(_var, _member, _type))