Revert "[C++11] Do not check __GXX_EXPERIMENTAL_CXX0X__."
authorRui Ueyama <ruiu@google.com>
Thu, 27 Mar 2014 22:36:06 +0000 (22:36 +0000)
committerRui Ueyama <ruiu@google.com>
Thu, 27 Mar 2014 22:36:06 +0000 (22:36 +0000)
This reverts commit r204964 because it disabled "= delete", "constexpr"
and "explicit" on GCC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204973 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Support/Compiler.h

index 8ede85539b4341b1337fd471dd7acc26c4b8b190..1edcd45bc3bb61611af925aa48878de8d10afdaf 100644 (file)
 /// public:
 ///   ...
 /// };
-#if __has_feature(cxx_deleted_functions) || LLVM_MSC_PREREQ(1800)
+#if __has_feature(cxx_deleted_functions) || \
+    defined(__GXX_EXPERIMENTAL_CXX0X__) || LLVM_MSC_PREREQ(1800)
 #define LLVM_DELETED_FUNCTION = delete
 #else
 #define LLVM_DELETED_FUNCTION
 #endif
 
-#if __has_feature(cxx_constexpr)
+#if __has_feature(cxx_constexpr) || defined(__GXX_EXPERIMENTAL_CXX0X__)
 # define LLVM_CONSTEXPR constexpr
 #else
 # define LLVM_CONSTEXPR
 /// \macro LLVM_EXPLICIT
 /// \brief Expands to explicit on compilers which support explicit conversion
 /// operators. Otherwise expands to nothing.
-#if __has_feature(cxx_explicit_conversions) || LLVM_MSC_PREREQ(1800)
+#if __has_feature(cxx_explicit_conversions) || \
+    defined(__GXX_EXPERIMENTAL_CXX0X__) || LLVM_MSC_PREREQ(1800)
 #define LLVM_EXPLICIT explicit
 #else
 #define LLVM_EXPLICIT