From f25b0650c02182beba01f998ac862c60a11cffd7 Mon Sep 17 00:00:00 2001 From: Yedidya Feldblum Date: Sun, 13 Sep 2015 13:23:17 -0700 Subject: [PATCH] Drop support for GCC < 4.8 in folly/experimental/Bits.h Summary: [Folly] Drop support for GCC < 4.8 in folly/experimental/Bits.h Can't stay indefinitely backcompat with older compilers. Reviewed By: @meyering Differential Revision: D2420133 --- folly/experimental/Bits.h | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/folly/experimental/Bits.h b/folly/experimental/Bits.h index c7de2a14..1c9185d6 100644 --- a/folly/experimental/Bits.h +++ b/folly/experimental/Bits.h @@ -57,8 +57,7 @@ struct BitsTraits, typename std::enable_if< static T loadRMW(const Unaligned& x) { #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wuninitialized" -// make sure we compile without warning on gcc 4.6 with -Wpragmas -#if __GNUC_PREREQ(4, 7) +#if !__clang__ // for gcc version [4.8, ?) #pragma GCC diagnostic ignored "-Wmaybe-uninitialized" #endif return x.value; @@ -79,8 +78,7 @@ struct BitsTraits, typename std::enable_if< loadRMW(const UnalignedNoASan& x) { #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wuninitialized" -// make sure we compile without warning on gcc 4.6 with -Wpragmas -#if __GNUC_PREREQ(4, 7) +#if !__clang__ // for gcc version [4.8, ?) #pragma GCC diagnostic ignored "-Wmaybe-uninitialized" #endif return x.value; @@ -98,7 +96,7 @@ struct BitsTraits