From b29f6896196376a6b3c2abf60de766811264af75 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 26 Jul 2015 14:31:14 +0300 Subject: Fix compiler features detection. --- src/localconsts.h | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'src/localconsts.h') diff --git a/src/localconsts.h b/src/localconsts.h index 5d73f8c53..560e5f152 100644 --- a/src/localconsts.h +++ b/src/localconsts.h @@ -47,7 +47,7 @@ #define noexcept #define A_DELETE(func) #define A_DELETE_COPY(func) -#else +#else // !defined(__GXX_EXPERIMENTAL_CXX0X__) #if GCC_VERSION < 40700 #define final #define override @@ -55,21 +55,25 @@ #define noexcept // #define A_DELETE // #define A_DELETE_COPY -#else +#else // GCC_VERSION < 40700 #define ADVGCC #if GCC_VERSION < 40900 #define constexpr2 -#else +#else // GCC_VERSION < 40900 +#if __cpp_constexpr > 201309 #define constexpr2 constexpr -#endif -#endif +#else // __cpp_constexpr > 201309 +#define constexpr2 +#endif // __cpp_constexpr > 201309 +#endif // GCC_VERSION < 40900 +#endif // GCC_VERSION < 40700 #undef Z_NULL #define Z_NULL nullptr #define M_TCPOK #define A_DELETE(func) func = delete #define A_DELETE_COPY(name) name(const name &) = delete; \ name &operator=(const name&) = delete; -#endif +#endif // !defined(__GXX_EXPERIMENTAL_CXX0X__) #ifdef __GNUC__ #define A_UNUSED __attribute__ ((unused)) -- cgit v1.2.3-60-g2f50