Bug 1266295 - Remove unnecessary compiler version checks for gcc <= 4.8.0 in xpcom. r=froydnj

This commit is contained in:
Chris Peterson 2016-04-17 17:10:00 -07:00
parent 1999c10d91
commit c2fe3cc9ea
2 changed files with 4 additions and 22 deletions

View File

@ -6,7 +6,6 @@
#include "mozilla/Assertions.h"
#include "mozilla/Attributes.h"
#include "mozilla/Compiler.h"
#include "mozilla/HashFunctions.h"
#include "mozilla/MemoryReporting.h"
#include "mozilla/DebugOnly.h"
@ -38,14 +37,6 @@
using namespace mozilla;
#if defined(__clang__)
# pragma GCC diagnostic ignored "-Wdelete-non-virtual-dtor"
#elif MOZ_IS_GCC
# if MOZ_GCC_VERSION_AT_LEAST(4, 7, 0)
# pragma GCC diagnostic ignored "-Wdelete-non-virtual-dtor"
# endif
#endif
//----------------------------------------------------------------------
class CheckStaticAtomSizes

View File

@ -38,14 +38,13 @@
// seem to handle the fallback just fine.
# define MOZ_CAN_USE_IS_DESTRUCTIBLE_FALLBACK
#elif defined(__GNUC__)
// GCC 4.7 is has buggy std::is_destructible
# if MOZ_USING_LIBSTDCXX && MOZ_GCC_VERSION_AT_LEAST(4, 8, 0)
// GCC 4.7 has buggy std::is_destructible.
# if MOZ_USING_LIBSTDCXX
# define MOZ_HAVE_STD_IS_DESTRUCTIBLE
# endif
// Some GCC versions have an ICE when using destructors in decltype().
// Works on GCC 4.8 at least.
# elif MOZ_GCC_VERSION_AT_LEAST(4, 8, 0)
# define MOZ_CAN_USE_IS_DESTRUCTIBLE_FALLBACK
# endif
# define MOZ_CAN_USE_IS_DESTRUCTIBLE_FALLBACK
#endif
#ifdef MOZ_HAVE_STD_IS_DESTRUCTIBLE
@ -140,14 +139,6 @@ private:
#define MOZ_ASSERT_CLASSNAME(_type) \
static_assert(mozilla::IsClass<_type>::value, \
"Token '" #_type "' is not a class type.")
// Older versions of gcc can't instantiate local classes in templates.
// GCC 4.7 doesn't have this problem.
#if MOZ_IS_GCC
# if !MOZ_GCC_VERSION_AT_LEAST(4, 7, 0)
# undef MOZ_ASSERT_CLASSNAME
# define MOZ_ASSERT_CLASSNAME(_type)
# endif
#endif
// Note that the following constructor/destructor logging macros are redundant
// for refcounted objects that log via the NS_LOG_ADDREF/NS_LOG_RELEASE macros.