From: Wolfgang Bumiller Date: Fri, 27 Jul 2012 17:02:39 +0000 (+0200) Subject: Merge branch 'master' into blub/bc3 X-Git-Tag: 0.1-rc1~372 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=975356cbce515a5d558a9def6f26a4b311965546;p=xonotic%2Fgmqcc.git Merge branch 'master' into blub/bc3 --- 975356cbce515a5d558a9def6f26a4b311965546 diff --cc gmqcc.h index 58e12cf,75dceaf..efb380b --- a/gmqcc.h +++ b/gmqcc.h @@@ -719,19 -769,9 +719,19 @@@ void Tself##_##mem##_clear(Tself *self (owner)->mem##_alloc = 0; \ } +#define MEM_VECTOR_MOVE(from, mem, to, tm) \ +{ \ + (to)->tm = (from)->mem; \ + (to)->tm##_count = (from)->mem##_count; \ + (to)->tm##_alloc = (from)->mem##_alloc; \ + (from)->mem = NULL; \ + (from)->mem##_count = 0; \ + (from)->mem##_alloc = 0; \ +} + #define MEM_VEC_FUNCTIONS(Tself, Twhat, mem) \ - _MEM_VEC_FUN_REMOVE(Tself, Twhat, mem) \ - _MEM_VEC_FUN_ADD(Tself, Twhat, mem) + MEM_VEC_FUN_REMOVE(Tself, Twhat, mem) \ + MEM_VEC_FUN_ADD(Tself, Twhat, mem) #define MEM_VEC_FUNCTIONS_ALL(Tself, Twhat, mem) \ MEM_VEC_FUNCTIONS(Tself, Twhat, mem) \