X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fcommon%2Futil.qh;h=166af391e9574b7d6e5e7f7867bab05ab43c2e7f;hp=d575bbfddbd3c32c3c70c9b210ebe6c76117b10c;hb=4f75649e4025f6af2730b0625b733a74944b02e7;hpb=e2ddf7d153328e3f2398d62d07c9e72badd89374 diff --git a/qcsrc/common/util.qh b/qcsrc/common/util.qh index d575bbfddb..166af391e9 100644 --- a/qcsrc/common/util.qh +++ b/qcsrc/common/util.qh @@ -6,6 +6,12 @@ // a dummy macro that prevents the "hanging ;" warning #define ENDS_WITH_CURLY_BRACE +#ifdef GMQCC +# define ACCUMULATE_FUNCTION(func,otherfunc) \ + [[accumulate]] void func() { otherfunc(); } +# define CALL_ACCUMULATED_FUNCTION(func) \ + func() +#else #ifdef HAVE_YO_DAWG_CPP // TODO make ascii art pic of xzibit // YO DAWG! @@ -41,6 +47,7 @@ void ACCUMULATE_call(string func) # define CALL_ACCUMULATED_FUNCTION(func) \ ACCUMULATE_call(#func) #endif +#endif // used for simplifying ACCUMULATE_FUNCTIONs #define SET_FIRST_OR_LAST(input,first,count) if(!input) { input = (first + count); }