Add _LIBCPP_COMPILER_[CLANG|GCC|MSVC|IBM] macros.

This patch refactors the compiler detection done in `__config` by creating a
set of `_LIBCPP_COMPILER_<TYPE>` macros. The goal of this patch is to make
it easier to detect what compiler is being used outside of `__config`.

Additionally this patch removes workarounds for GCC in `__bit_reference`. I
tested GCC 4.8 and 4.9 without the workaround and neither seemed to need it
anymore.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@291286 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Fiselier
2017-01-06 21:42:58 +00:00
parent 8eb066a106
commit 5170d7d88f
5 changed files with 32 additions and 32 deletions

View File

@@ -140,7 +140,7 @@ class _LIBCPP_HIDDEN locale::__imp
: public facet
{
enum {N = 28};
#if defined(_LIBCPP_MSVC)
#if defined(_LIBCPP_COMPILER_MSVC)
// FIXME: MSVC doesn't support aligned parameters by value.
// I can't get the __sso_allocator to work here
// for MSVC I think for this reason.