From adbb92561576ab614c79b60cc301e6ba6e7a7cb3 Mon Sep 17 00:00:00 2001 From: Lukas Mai Date: Tue, 2 Dec 2014 00:05:50 +0100 Subject: [PATCH] static_assert workaround for AIX/xlc --- perl.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/perl.h b/perl.h index 55918d0..0c8963f 100644 --- a/perl.h +++ b/perl.h @@ -3504,10 +3504,12 @@ typedef pthread_key_t perl_key; /* placeholder */ #endif -#if defined(static_assert) || (defined(__cplusplus) && __cplusplus >= 201103L) /* static_assert is a macro defined in in C11 or a compiler builtin in C++11. */ +#if (defined(static_assert) || (defined(__cplusplus) && __cplusplus >= 201103L)) \ + && (!defined(__IBMC__) || __IBMC__ >= 1210) + /* IBM XL C V11 does not support _Static_assert, no matter what says */ # define STATIC_ASSERT_GLOBAL(COND) static_assert(COND, #COND) #else /* We use a bit-field instead of an array because gcc accepts -- 2.1.3