diff options
Diffstat (limited to 'Alc/vector.h')
-rw-r--r-- | Alc/vector.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Alc/vector.h b/Alc/vector.h index 242c5fa5..b4a843d5 100644 --- a/Alc/vector.h +++ b/Alc/vector.h @@ -59,4 +59,11 @@ ALboolean vector_insert(void *ptr, size_t base_size, size_t obj_size, void *ins_ #define VECTOR_ELEM(_x, _o) ((_x)->Data[(_o)]) +#define VECTOR_FOR_EACH(_t, _x, _f) do { \ + _t *_iter = VECTOR_ITER_BEGIN((_x)); \ + _t *_end = VECTOR_ITER_END((_x)); \ + for(;_iter != _end;++_iter) \ + (_f)(_iter); \ +} while(0) + #endif /* AL_VECTOR_H */ |