summaryrefslogtreecommitdiffstats
path: root/test/Lexer
diff options
context:
space:
mode:
Diffstat (limited to 'test/Lexer')
-rw-r--r--test/Lexer/has_feature_cxx0x.cpp38
-rw-r--r--test/Lexer/pragma-message.c2
2 files changed, 39 insertions, 1 deletions
diff --git a/test/Lexer/has_feature_cxx0x.cpp b/test/Lexer/has_feature_cxx0x.cpp
index 07a3ebd..57949e3 100644
--- a/test/Lexer/has_feature_cxx0x.cpp
+++ b/test/Lexer/has_feature_cxx0x.cpp
@@ -41,6 +41,16 @@ int no_auto_type();
// CHECK-NO-0X: no_auto_type
+#if __has_feature(cxx_trailing_return)
+int has_trailing_return();
+#else
+int no_trailing_return();
+#endif
+
+// CHECK-0X: has_trailing_return
+// CHECK-NO-0X: no_trailing_return
+
+
#if __has_feature(cxx_attributes)
int has_attributes();
#else
@@ -99,6 +109,17 @@ int no_inline_namespaces();
// CHECK-0X: has_inline_namespaces
// CHECK-NO-0X: no_inline_namespaces
+
+#if __has_feature(cxx_range_for)
+int has_range_for();
+#else
+int no_range_for();
+#endif
+
+// CHECK-0X: has_range_for
+// CHECK-NO-0X: no_range_for
+
+
#if __has_feature(cxx_reference_qualified_functions)
int has_reference_qualified_functions();
#else
@@ -117,3 +138,20 @@ int no_default_function_template_args();
// CHECK-0X: has_default_function_template_args
// CHECK-NO-0X: no_default_function_template_args
+#if __has_feature(cxx_noexcept)
+int has_noexcept();
+#else
+int no_noexcept();
+#endif
+
+// CHECK-0X: has_noexcept
+// CHECK-NO-0X: no_noexcept
+
+#if __has_feature(cxx_override_control)
+int has_override_control();
+#else
+int no_override_control();
+#endif
+
+// CHECK-0X: has_override_control
+// CHECK-NO-0X: no_override_control
diff --git a/test/Lexer/pragma-message.c b/test/Lexer/pragma-message.c
index 710568c..807edda 100644
--- a/test/Lexer/pragma-message.c
+++ b/test/Lexer/pragma-message.c
@@ -7,7 +7,7 @@
// OR
// #pragma message messagestring
//
-// RUN: %clang_cc1 -fsyntax-only -verify %s
+// RUN: %clang_cc1 -fsyntax-only -verify -Werror %s
#define STRING2(x) #x
#define STRING(x) STRING2(x)
#pragma message(":O I'm a message! " STRING(__LINE__)) // expected-warning {{:O I'm a message! 13}}
OpenPOWER on IntegriCloud