diff --git a/source/lib/code_annotation.h b/source/lib/code_annotation.h index 98c945a865..b8bb6d8adc 100644 --- a/source/lib/code_annotation.h +++ b/source/lib/code_annotation.h @@ -314,17 +314,6 @@ switch(x % 2) // number of array elements // -#if GCC_VERSION - -// The function trick below does not work in GCC. Instead use the old fashioned -// divide-by-sizeof-element. This causes problems when the argument to -// ARRAY_SIZE is a pointer and not an array, but we will catch those when we -// compile on something other than GCC. - -#define ARRAY_SIZE(name) (sizeof(name) / (sizeof((name)[0]))) - -#else - // (function taking a reference to an array and returning a pointer to // an array of characters. it's only declared and never defined; we just // need it to determine n, the size of the array that was passed.) @@ -335,7 +324,6 @@ template char (*ArraySizeDeducer(T (&)[n]))[n]; // pointer is passed, which can easily happen under maintenance.) #define ARRAY_SIZE(name) (sizeof(*ArraySizeDeducer(name))) -#endif // GCC_VERSION // C99-style __func__ // .. newer GCC already have it