Switch diagnostic text from "C++0x" over to "C++11".

We'd also like for "C++11" or "c++11" to be used for the warning
groups, but without removing the old warning flags. Patches welcome;
I've run out of time to work on this today.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141801 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/CXX/class.access/class.friend/p2-cxx03.cpp b/test/CXX/class.access/class.friend/p2-cxx03.cpp
index 82cddc2..f8cabfd 100644
--- a/test/CXX/class.access/class.friend/p2-cxx03.cpp
+++ b/test/CXX/class.access/class.friend/p2-cxx03.cpp
@@ -1,7 +1,7 @@
 // RUN: %clang_cc1 -fsyntax-only -verify %s
 template<typename T>
 class X0 {
-  friend T; // expected-warning{{non-class friend type 'T' is a C++0x extension}}
+  friend T; // expected-warning{{non-class friend type 'T' is a C++11 extension}}
 };
 
 class X1 { };
diff --git a/test/CXX/class/class.friend/p2.cpp b/test/CXX/class/class.friend/p2.cpp
index 87b69c0..fb3cd19 100644
--- a/test/CXX/class/class.friend/p2.cpp
+++ b/test/CXX/class/class.friend/p2.cpp
@@ -4,7 +4,7 @@
 
 class A {
   friend class B {}; // expected-error {{cannot define a type in a friend declaration}}
-  friend int; // expected-warning {{non-class friend type 'int' is a C++0x extension}}
+  friend int; // expected-warning {{non-class friend type 'int' is a C++11 extension}}
   friend B0; // expected-warning {{specify 'struct' to befriend 'B0'}}
   friend class C; // okay
 };
diff --git a/test/CXX/class/class.friend/p6.cpp b/test/CXX/class/class.friend/p6.cpp
index 0b173b5..82a90ff 100644
--- a/test/CXX/class/class.friend/p6.cpp
+++ b/test/CXX/class/class.friend/p6.cpp
@@ -3,7 +3,7 @@
 class A {
   friend static class B; // expected-error {{'static' is invalid in friend declarations}}
   friend extern class C; // expected-error {{'extern' is invalid in friend declarations}}
-  friend auto class D; // expected-warning {{incompatible with C++0x}} expected-error {{'auto' is invalid in friend declarations}}
+  friend auto class D; // expected-warning {{incompatible with C++11}} expected-error {{'auto' is invalid in friend declarations}}
   friend register class E; // expected-error {{'register' is invalid in friend declarations}}
   friend mutable class F; // expected-error {{'mutable' is invalid in friend declarations}}
   friend typedef class G; // expected-error {{'typedef' is invalid in friend declarations}}
diff --git a/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p6.cpp b/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p6.cpp
index fcc1334..ee870d9 100644
--- a/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p6.cpp
+++ b/test/CXX/dcl.dcl/dcl.spec/dcl.fct.spec/p6.cpp
@@ -4,7 +4,7 @@
 public:
   explicit A();
   
-  explicit operator int(); // expected-warning {{explicit conversion functions are a C++0x extension}}
+  explicit operator int(); // expected-warning {{explicit conversion functions are a C++11 extension}}
 
   explicit void f0(); // expected-error {{'explicit' can only be applied to a constructor or conversion function}}
   
@@ -12,5 +12,5 @@
 };
 
 explicit A::A() { } // expected-error {{'explicit' can only be specified inside the class definition}}
-explicit A::operator bool() { return false; }  // expected-warning {{explicit conversion functions are a C++0x extension}}\
+explicit A::operator bool() { return false; }  // expected-warning {{explicit conversion functions are a C++11 extension}}\
                                                // expected-error {{'explicit' can only be specified inside the class definition}}
diff --git a/test/CXX/temp/temp.param/p15.cpp b/test/CXX/temp/temp.param/p15.cpp
index 1308779..ee572e9 100644
--- a/test/CXX/temp/temp.param/p15.cpp
+++ b/test/CXX/temp/temp.param/p15.cpp
@@ -9,4 +9,4 @@
     >> *x3;   // expected-error{{a space is required between consecutive right angle brackets (use '> >')}}
 
 Y<(1 >> 2)> *y1;
-Y<1 >> 2> *y2; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++0x}}
+Y<1 >> 2> *y2; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++11}}
diff --git a/test/CXX/temp/temp.param/p9.cpp b/test/CXX/temp/temp.param/p9.cpp
index 62af522..b2318c2 100644
--- a/test/CXX/temp/temp.param/p9.cpp
+++ b/test/CXX/temp/temp.param/p9.cpp
@@ -2,9 +2,9 @@
 
 // A default template-argument shall not be specified in a function
 // template declaration or a function template definition
-template<typename T = int> // expected-warning{{default template arguments for a function template are a C++0x extension}}
+template<typename T = int> // expected-warning{{default template arguments for a function template are a C++11 extension}}
   void foo0(T); 
-template<typename T = int> // expected-warning{{default template arguments for a function template are a C++0x extension}} 
+template<typename T = int> // expected-warning{{default template arguments for a function template are a C++11 extension}} 
   void foo1(T) { } 
 
 // [...] nor in the template-parameter-list of the definition of a
diff --git a/test/CodeGenObjCXX/blocks.mm b/test/CodeGenObjCXX/blocks.mm
index db88db2..126931d 100644
--- a/test/CodeGenObjCXX/blocks.mm
+++ b/test/CodeGenObjCXX/blocks.mm
@@ -30,7 +30,7 @@
 
 // Test4
 struct S {
-  S *(^a)() = ^{ // expected-warning {{C++0x}}
+  S *(^a)() = ^{ // expected-warning {{C++11}}
     return this;
   };
 };
@@ -40,7 +40,7 @@
 struct X {
   void f() {
     ^ {
-      struct Nested { Nested *ptr = this; }; // expected-warning {{C++0x}}
+      struct Nested { Nested *ptr = this; }; // expected-warning {{C++11}}
     } ();
   };
 };
diff --git a/test/Parser/cxx-ext-delete-default.cpp b/test/Parser/cxx-ext-delete-default.cpp
index 0627238..be6efee 100644
--- a/test/Parser/cxx-ext-delete-default.cpp
+++ b/test/Parser/cxx-ext-delete-default.cpp
@@ -1,11 +1,11 @@
 // RUN: %clang_cc1 -fsyntax-only -verify -std=c++98 %s
 
 struct A {
-  A(const A&) = delete; // expected-warning {{accepted as a C++0x extension}}
-  A& operator=(const A&) = delete; // expected-warning {{accepted as a C++0x extension}}
-  A() = default; // expected-warning {{accepted as a C++0x extension}}
+  A(const A&) = delete; // expected-warning {{accepted as a C++11 extension}}
+  A& operator=(const A&) = delete; // expected-warning {{accepted as a C++11 extension}}
+  A() = default; // expected-warning {{accepted as a C++11 extension}}
   ~A();
 };
 
-void f() = delete; // expected-warning {{accepted as a C++0x extension}}
-A::~A() = default; //expected-warning {{accepted as a C++0x extension}}
+void f() = delete; // expected-warning {{accepted as a C++11 extension}}
+A::~A() = default; //expected-warning {{accepted as a C++11 extension}}
diff --git a/test/Parser/cxx-reference.cpp b/test/Parser/cxx-reference.cpp
index fae938b..d21412c 100644
--- a/test/Parser/cxx-reference.cpp
+++ b/test/Parser/cxx-reference.cpp
@@ -18,4 +18,4 @@
 int & const volatile Z = val; /* expected-error {{'const' qualifier may not be applied}} \
                            expected-error {{'volatile' qualifier may not be applied}} */
 
-typedef int && RV; // expected-warning {{rvalue references are a C++0x extension}}
+typedef int && RV; // expected-warning {{rvalue references are a C++11 extension}}
diff --git a/test/Parser/cxx0x-in-cxx98.cpp b/test/Parser/cxx0x-in-cxx98.cpp
index e0cbc23..9e41a70 100644
--- a/test/Parser/cxx0x-in-cxx98.cpp
+++ b/test/Parser/cxx0x-in-cxx98.cpp
@@ -1,10 +1,10 @@
 // RUN: %clang_cc1 -std=c++98 -fsyntax-only -verify %s
 
-inline namespace N { // expected-warning{{inline namespaces are a C++0x feature}}
+inline namespace N { // expected-warning{{inline namespaces are a C++11 feature}}
 struct X {
-  template<typename ...Args> // expected-warning{{variadic templates are a C++0x extension}}
-  void f(Args &&...) &; // expected-warning{{rvalue references are a C++0x extension}} \
-  // expected-warning{{reference qualifiers on functions are a C++0x extension}}
+  template<typename ...Args> // expected-warning{{variadic templates are a C++11 extension}}
+  void f(Args &&...) &; // expected-warning{{rvalue references are a C++11 extension}} \
+  // expected-warning{{reference qualifiers on functions are a C++11 extension}}
 };
 }
 
diff --git a/test/SemaCXX/PR10458.cpp b/test/SemaCXX/PR10458.cpp
index e1f077a..57588eb 100644
--- a/test/SemaCXX/PR10458.cpp
+++ b/test/SemaCXX/PR10458.cpp
@@ -2,6 +2,6 @@
 
 void f() {
   int arr[] = { 1, 2, 3 };
-  for (auto &i : arr) { // expected-warning {{'auto' type specifier is a C++0x extension}} expected-warning {{range-based for loop is a C++0x extension}}
+  for (auto &i : arr) { // expected-warning {{'auto' type specifier is a C++11 extension}} expected-warning {{range-based for loop is a C++11 extension}}
   }
 }
diff --git a/test/SemaCXX/PR9572.cpp b/test/SemaCXX/PR9572.cpp
index 25c0c01..b0bbfa6 100644
--- a/test/SemaCXX/PR9572.cpp
+++ b/test/SemaCXX/PR9572.cpp
@@ -3,7 +3,7 @@
   virtual ~Base(); // expected-note {{implicitly declared private here}}
 };
 struct Foo : public Base { // expected-error {{base class 'Base' has private destructor}}
-  const int kBlah = 3; // expected-warning {{accepted as a C++0x extension}}
+  const int kBlah = 3; // expected-warning {{accepted as a C++11 extension}}
   Foo();
 };
 struct Bar : public Foo {
diff --git a/test/SemaCXX/auto-cxx0x.cpp b/test/SemaCXX/auto-cxx0x.cpp
index a7bb3e6..fb9f509 100644
--- a/test/SemaCXX/auto-cxx0x.cpp
+++ b/test/SemaCXX/auto-cxx0x.cpp
@@ -1,5 +1,5 @@
 // RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++0x
 void f() {
-  auto int a; // expected-warning {{'auto' storage class specifier is not permitted in C++0x, and will not be supported in future releases}}
+  auto int a; // expected-warning {{'auto' storage class specifier is not permitted in C++11, and will not be supported in future releases}}
   int auto b; // expected-error{{cannot combine with previous 'int' declaration specifier}}
 }
diff --git a/test/SemaCXX/auto-cxx98.cpp b/test/SemaCXX/auto-cxx98.cpp
index 8d22469..6c401ba 100644
--- a/test/SemaCXX/auto-cxx98.cpp
+++ b/test/SemaCXX/auto-cxx98.cpp
@@ -1,8 +1,8 @@
 // RUN: %clang_cc1 -fsyntax-only -verify %s -std=c++98
 void f() {
-  auto int a; // expected-warning {{'auto' storage class specifier is redundant and incompatible with C++0x}}
-  int auto b; // expected-warning {{'auto' storage class specifier is redundant and incompatible with C++0x}}
-  auto c; // expected-warning {{C++0x extension}} expected-error {{requires an initializer}}
-  static auto d = 0; // expected-warning {{C++0x extension}}
-  auto static e = 0; // expected-warning {{C++0x extension}}
+  auto int a; // expected-warning {{'auto' storage class specifier is redundant and incompatible with C++11}}
+  int auto b; // expected-warning {{'auto' storage class specifier is redundant and incompatible with C++11}}
+  auto c; // expected-warning {{C++11 extension}} expected-error {{requires an initializer}}
+  static auto d = 0; // expected-warning {{C++11 extension}}
+  auto static e = 0; // expected-warning {{C++11 extension}}
 }
diff --git a/test/SemaCXX/class.cpp b/test/SemaCXX/class.cpp
index 52b062b..160f365 100644
--- a/test/SemaCXX/class.cpp
+++ b/test/SemaCXX/class.cpp
@@ -34,12 +34,12 @@
 
   enum E1 { en1, en2 };
 
-  int i = 0; // expected-warning {{in-class initialization of non-static data member accepted as a C++0x extension}}
+  int i = 0; // expected-warning {{in-class initialization of non-static data member accepted as a C++11 extension}}
   static int si = 0; // expected-error {{non-const static data member must be initialized out of line}}
   static const NestedC ci = 0; // expected-error {{static data member of type 'const C::NestedC' must be initialized out of line}}
   static const int nci = vs; // expected-error {{in-class initializer is not a constant expression}}
   static const int vi = 0;
-  static const volatile int cvi = 0; // ok, illegal in C++0x
+  static const volatile int cvi = 0; // ok, illegal in C++11
   static const E evi = 0;
 
   void m() {
diff --git a/test/SemaCXX/convert-to-bool.cpp b/test/SemaCXX/convert-to-bool.cpp
index 4cd22e9..c9a3555 100644
--- a/test/SemaCXX/convert-to-bool.cpp
+++ b/test/SemaCXX/convert-to-bool.cpp
@@ -8,7 +8,7 @@
 };
 
 struct ExplicitConvToBool {
-  explicit operator bool(); // expected-warning{{explicit conversion functions are a C++0x extension}}
+  explicit operator bool(); // expected-warning{{explicit conversion functions are a C++11 extension}}
 };
 
 void test_conv_to_bool(ConvToBool ctb, ConvToInt cti, ExplicitConvToBool ecb) {
@@ -39,7 +39,7 @@
 void accepts_bool(bool) { } // expected-note{{candidate function}}
 
 struct ExplicitConvToRef {
-  explicit operator int&(); // expected-warning{{explicit conversion functions are a C++0x extension}}
+  explicit operator int&(); // expected-warning{{explicit conversion functions are a C++11 extension}}
 };
 
 void test_explicit_bool(ExplicitConvToBool ecb) {
@@ -56,7 +56,7 @@
 struct A { };
 struct B { };
 struct C {
-  explicit operator A&(); // expected-warning{{explicit conversion functions are a C++0x extension}}
+  explicit operator A&(); // expected-warning{{explicit conversion functions are a C++11 extension}}
   operator B&(); // expected-note{{candidate}}
 };
 
diff --git a/test/SemaCXX/cxx0x-compat.cpp b/test/SemaCXX/cxx0x-compat.cpp
index 1c4cbb2..a01b26c 100644
--- a/test/SemaCXX/cxx0x-compat.cpp
+++ b/test/SemaCXX/cxx0x-compat.cpp
@@ -13,12 +13,12 @@
 }
 
 void f() {
-  auto int n = 0; // expected-warning {{'auto' storage class specifier is redundant and incompatible with C++0x}}
+  auto int n = 0; // expected-warning {{'auto' storage class specifier is redundant and incompatible with C++11}}
 }
 
 int n;
 struct S {
   char c;
 }
-s = { n }, // expected-warning {{non-constant-expression cannot be narrowed from type 'int' to 'char' in initializer list in C++0x}} expected-note {{explicit cast}}
-t = { 1234 }; // expected-warning {{constant expression evaluates to 1234 which cannot be narrowed to type 'char' in C++0x}} expected-warning {{changes value}} expected-note {{explicit cast}}
+s = { n }, // expected-warning {{non-constant-expression cannot be narrowed from type 'int' to 'char' in initializer list in C++11}} expected-note {{explicit cast}}
+t = { 1234 }; // expected-warning {{constant expression evaluates to 1234 which cannot be narrowed to type 'char' in C++11}} expected-warning {{changes value}} expected-note {{explicit cast}}
diff --git a/test/SemaCXX/cxx0x-return-init-list.cpp b/test/SemaCXX/cxx0x-return-init-list.cpp
index 2005a7f..b786922 100644
--- a/test/SemaCXX/cxx0x-return-init-list.cpp
+++ b/test/SemaCXX/cxx0x-return-init-list.cpp
@@ -1,17 +1,17 @@
 // RUN: %clang_cc1 -fsyntax-only -verify %s
 
 // This test checks for a teeny tiny subset of the functionality in
-// the C++0x generalized initializer lists feature, which happens to
+// the C++11 generalized initializer lists feature, which happens to
 // be used in libstdc++ 4.5. We accept only this syntax so that Clang
 // can handle the libstdc++ 4.5 headers.
 
 int test0(int i) {
-  return { i }; // expected-warning{{generalized initializer lists are a C++0x extension unsupported in Clang}}
+  return { i }; // expected-warning{{generalized initializer lists are a C++11 extension unsupported in Clang}}
 }
 
 template<typename T, typename U>
 T test1(U u) {
-  return { u }; // expected-warning{{generalized initializer lists are a C++0x extension unsupported in Clang}}
+  return { u }; // expected-warning{{generalized initializer lists are a C++11 extension unsupported in Clang}}
 }
 
 template int test1(char);
diff --git a/test/SemaCXX/new-array-size-conv.cpp b/test/SemaCXX/new-array-size-conv.cpp
index 80219a9..e8bb679 100644
--- a/test/SemaCXX/new-array-size-conv.cpp
+++ b/test/SemaCXX/new-array-size-conv.cpp
@@ -19,8 +19,8 @@
 struct TwoValueInts : ValueInt, IndirectValueInt { };
 
 void test() {
-  (void)new int[ValueInt(10)]; // expected-warning{{implicit conversion from array size expression of type 'ValueInt' to integral type 'int' is a C++0x extension}}
-  (void)new int[ValueEnum()]; // expected-warning{{implicit conversion from array size expression of type 'ValueEnum' to enumeration type 'E' is a C++0x extension}}
+  (void)new int[ValueInt(10)]; // expected-warning{{implicit conversion from array size expression of type 'ValueInt' to integral type 'int' is a C++11 extension}}
+  (void)new int[ValueEnum()]; // expected-warning{{implicit conversion from array size expression of type 'ValueEnum' to enumeration type 'E' is a C++11 extension}}
   (void)new int[ValueBoth()]; // expected-error{{ambiguous conversion of array size expression of type 'ValueBoth' to an integral or enumeration type}}
 
   (void)new int[TwoValueInts()]; // expected-error{{ambiguous conversion of array size expression of type 'TwoValueInts' to an integral or enumeration type}}
diff --git a/test/SemaTemplate/instantiate-function-2.cpp b/test/SemaTemplate/instantiate-function-2.cpp
index 087ede2..19a8b61 100644
--- a/test/SemaTemplate/instantiate-function-2.cpp
+++ b/test/SemaTemplate/instantiate-function-2.cpp
@@ -46,7 +46,7 @@
 namespace AliasTagDef {
   template<typename T>
   T f() {
-    using S = struct { // expected-warning {{C++0x}}
+    using S = struct { // expected-warning {{C++11}}
       T g() {
         return T();
       }
diff --git a/test/SemaTemplate/instantiate-member-class.cpp b/test/SemaTemplate/instantiate-member-class.cpp
index 1028b45..c67eb40 100644
--- a/test/SemaTemplate/instantiate-member-class.cpp
+++ b/test/SemaTemplate/instantiate-member-class.cpp
@@ -108,7 +108,7 @@
 namespace AliasTagDef {
   template<typename T>
   struct F {
-    using S = struct U { // expected-warning {{C++0x}}
+    using S = struct U { // expected-warning {{C++11}}
       T g() {
         return T();
       }
diff --git a/test/SemaTemplate/temp_arg_nontype.cpp b/test/SemaTemplate/temp_arg_nontype.cpp
index e93cfa3..43fe38b 100644
--- a/test/SemaTemplate/temp_arg_nontype.cpp
+++ b/test/SemaTemplate/temp_arg_nontype.cpp
@@ -7,7 +7,7 @@
 
 A<int> *a2; // expected-error{{template argument for non-type template parameter must be an expression}}
 
-A<1 >> 2> *a3; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++0x}}
+A<1 >> 2> *a3; // expected-warning{{use of right-shift operator ('>>') in template argument will require parentheses in C++11}}
 
 // C++ [temp.arg.nontype]p5:
 A<A> *a4; // expected-error{{must be an expression}}