]> granicus.if.org Git - clang/commitdiff
Remember to add a has_feature macro for __underlying_type now that it is
authorSean Hunt <scshunt@csclub.uwaterloo.ca>
Mon, 18 Jul 2011 17:08:00 +0000 (17:08 +0000)
committerSean Hunt <scshunt@csclub.uwaterloo.ca>
Mon, 18 Jul 2011 17:08:00 +0000 (17:08 +0000)
correctly impelmented

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

lib/Lex/PPMacroExpansion.cpp
test/Lexer/has_feature_type_traits.cpp

index ecd4d4cfc68b2fef82349460d6a255d47a3f8d7a..e8658255e4005d71b483ab589c86d06780de87b0 100644 (file)
@@ -649,6 +649,7 @@ static bool HasFeature(const Preprocessor &PP, const IdentifierInfo *II) {
            .Case("is_trivially_copyable", LangOpts.CPlusPlus)
            .Case("is_union", LangOpts.CPlusPlus)
            .Case("tls", PP.getTargetInfo().isTLSSupported())
+           .Case("underlying_type", LangOpts.CPlusPlus)
            .Default(false);
 }
 
index 5da845f06512085bb3c90a9182733d406ba39d2c..53056a02b72a58e0e3566359317b61c7166fb72f 100644 (file)
@@ -99,3 +99,8 @@ int is_standard_layout();
 int is_trivially_copyable();
 #endif
 // CHECK: int is_trivially_copyable();
+
+#if __has_feature(underlying_type)
+int underlying_type();
+#endif
+// CHECK: int underlying_type();