diff options
Diffstat (limited to 'src/localconsts.h')
-rw-r--r-- | src/localconsts.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/localconsts.h b/src/localconsts.h index 549838619..777d0f540 100644 --- a/src/localconsts.h +++ b/src/localconsts.h @@ -85,6 +85,9 @@ #define FOR_EACH(type, iter, array) for (type iter = array.begin(), \ iter##_end = array.end(); iter != iter##_end; ++ iter) +#define FOR_EACHR(type, iter, array) for (type iter = array.rbegin(), \ + iter##_end = array.rend(); iter != iter##_end; ++ iter) + #define FOR_EACHP(type, iter, array) for (type iter = array->begin(), \ iter##_end = array->end(); iter != iter##_end; ++ iter) |