X-Git-Url: http://de.git.xonotic.org/?p=xonotic%2Fxonotic-data.pk3dir.git;a=blobdiff_plain;f=qcsrc%2Fcommon%2Futil.qh;h=effdb3cf7823ff8089ed0099a1808fd5e37e3e11;hp=10920c3a891cae60320606beac394656ee702626;hb=bc20da5a3271b337049a25f68ddecad472b8db98;hpb=56e378ae75002cadb9e8908a6562817b682220d4;ds=sidebyside diff --git a/qcsrc/common/util.qh b/qcsrc/common/util.qh index 10920c3a89..effdb3cf78 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); }