[OPENMP] Fix DSA processing for member declaration.

If the member declaration is captured in the OMPCapturedExprDecl, we may
loose data-sharing attribute info for this declaration. Patch fixes this
bug.

llvm-svn: 308629
diff --git a/clang/test/OpenMP/distribute_parallel_for_lastprivate_messages.cpp b/clang/test/OpenMP/distribute_parallel_for_lastprivate_messages.cpp
index 745007f..ebc7a66 100644
--- a/clang/test/OpenMP/distribute_parallel_for_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/distribute_parallel_for_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/distribute_parallel_for_reduction_messages.cpp b/clang/test/OpenMP/distribute_parallel_for_reduction_messages.cpp
index 95654a9..0bf1bc0 100644
--- a/clang/test/OpenMP/distribute_parallel_for_reduction_messages.cpp
+++ b/clang/test/OpenMP/distribute_parallel_for_reduction_messages.cpp
@@ -27,9 +27,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/distribute_parallel_for_simd_lastprivate_messages.cpp b/clang/test/OpenMP/distribute_parallel_for_simd_lastprivate_messages.cpp
index 109fde0..e54089d 100644
--- a/clang/test/OpenMP/distribute_parallel_for_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/distribute_parallel_for_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/distribute_parallel_for_simd_reduction_messages.cpp b/clang/test/OpenMP/distribute_parallel_for_simd_reduction_messages.cpp
index 6ad41d7..94e4541 100644
--- a/clang/test/OpenMP/distribute_parallel_for_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/distribute_parallel_for_simd_reduction_messages.cpp
@@ -27,9 +27,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/distribute_simd_lastprivate_messages.cpp b/clang/test/OpenMP/distribute_simd_lastprivate_messages.cpp
index 0f96cb4..a891435 100644
--- a/clang/test/OpenMP/distribute_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/distribute_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/distribute_simd_reduction_messages.cpp b/clang/test/OpenMP/distribute_simd_reduction_messages.cpp
index fca3e85..ddedcb0 100644
--- a/clang/test/OpenMP/distribute_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/distribute_simd_reduction_messages.cpp
@@ -27,9 +27,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/dump.cpp b/clang/test/OpenMP/dump.cpp
index 378b53c..5ec202c 100644
--- a/clang/test/OpenMP/dump.cpp
+++ b/clang/test/OpenMP/dump.cpp
@@ -52,11 +52,11 @@
 // CHECK-NEXT: |       |-OMPScheduleClause {{.+}} <col:61, col:79>
 // CHECK-NEXT: |       | `-ImplicitCastExpr {{.+}} <col:78> 'int' <LValueToRValue>
 // CHECK-NEXT: |       |   `-DeclRefExpr {{.+}} <col:78> 'int' lvalue OMPCapturedExpr {{.+}} '.capture_expr.' 'int'
-// CHECK-NEXT: |       |-CapturedStmt {{.+}} <line:40:5, <invalid sloc>>
+// CHECK-NEXT: |       |-CapturedStmt {{.+}} <line:40:5, line:41:9>
 // CHECK-NEXT: |       | |-CapturedDecl {{.+}} <<invalid sloc>> <invalid sloc>
-// CHECK-NEXT: |       | | |-ForStmt {{.+}} <col:5, <invalid sloc>>
-// CHECK:      |       | | | `-UnaryOperator {{.+}} <line:41:7, <invalid sloc>> 'int' lvalue prefix '++'
-// CHECK-NEXT: |       | | |   `-DeclRefExpr {{.+}} <<invalid sloc>> 'int' lvalue OMPCapturedExpr {{.+}} 'a' 'int &'
+// CHECK-NEXT: |       | | |-ForStmt {{.+}} <line:40:5, line:41:9>
+// CHECK:      |       | | | `-UnaryOperator {{.+}} <line:41:7, col:9> 'int' lvalue prefix '++'
+// CHECK-NEXT: |       | | |   `-DeclRefExpr {{.+}} <col:9> 'int' lvalue OMPCapturedExpr {{.+}} 'a' 'int &'
 
 #pragma omp declare simd
 #pragma omp declare simd inbranch
diff --git a/clang/test/OpenMP/for_lastprivate_messages.cpp b/clang/test/OpenMP/for_lastprivate_messages.cpp
index 79912b6..13ef35e 100644
--- a/clang/test/OpenMP/for_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/for_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/for_reduction_messages.cpp b/clang/test/OpenMP/for_reduction_messages.cpp
index bb70ecc..d4f4a79 100644
--- a/clang/test/OpenMP/for_reduction_messages.cpp
+++ b/clang/test/OpenMP/for_reduction_messages.cpp
@@ -26,9 +26,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/for_simd_lastprivate_messages.cpp b/clang/test/OpenMP/for_simd_lastprivate_messages.cpp
index d48c07d..a176a2d 100644
--- a/clang/test/OpenMP/for_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/for_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   S2 &operator =(const S2&);
   const S2 &operator =(const S2&) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/for_simd_reduction_messages.cpp b/clang/test/OpenMP/for_simd_reduction_messages.cpp
index 485070e..a77ab75 100644
--- a/clang/test/OpenMP/for_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/for_simd_reduction_messages.cpp
@@ -26,9 +26,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/parallel_for_lastprivate_messages.cpp b/clang/test/OpenMP/parallel_for_lastprivate_messages.cpp
index ccfe2ea..134100b 100644
--- a/clang/test/OpenMP/parallel_for_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/parallel_for_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   S2 &operator=(const S2 &);
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/parallel_for_reduction_messages.cpp b/clang/test/OpenMP/parallel_for_reduction_messages.cpp
index 57ab1fa..6499ef5 100644
--- a/clang/test/OpenMP/parallel_for_reduction_messages.cpp
+++ b/clang/test/OpenMP/parallel_for_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
@@ -61,6 +61,12 @@
 
 public:
   S5(int v) : a(v) {}
+  void foo() {
+#pragma omp parallel private(a) // expected-note {{defined as private}}
+#pragma omp for reduction(+:a) // expected-error {{reduction variable must be shared}}
+  for (int i = 0; i < 10; ++i)
+    ::foo();
+  }
 };
 class S6 { // expected-note 3 {{candidate function (the implicit copy assignment operator) not viable: no known conversion from 'int' to 'const S6' for 1st argument}}
 #if __cplusplus >= 201103L // C++11 or later
diff --git a/clang/test/OpenMP/parallel_for_simd_lastprivate_messages.cpp b/clang/test/OpenMP/parallel_for_simd_lastprivate_messages.cpp
index bd1a6d5..8670e55 100644
--- a/clang/test/OpenMP/parallel_for_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/parallel_for_simd_lastprivate_messages.cpp
@@ -17,9 +17,9 @@
   S2(S2 &s2) : a(s2.a) {}
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/parallel_for_simd_reduction_messages.cpp b/clang/test/OpenMP/parallel_for_simd_reduction_messages.cpp
index 60a947d..8ff246e 100644
--- a/clang/test/OpenMP/parallel_for_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/parallel_for_simd_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/parallel_reduction_messages.cpp b/clang/test/OpenMP/parallel_reduction_messages.cpp
index 947353f..96f4b58 100644
--- a/clang/test/OpenMP/parallel_reduction_messages.cpp
+++ b/clang/test/OpenMP/parallel_reduction_messages.cpp
@@ -24,9 +24,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/parallel_sections_lastprivate_messages.cpp b/clang/test/OpenMP/parallel_sections_lastprivate_messages.cpp
index af3c5e2..eccbfc5 100644
--- a/clang/test/OpenMP/parallel_sections_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/parallel_sections_lastprivate_messages.cpp
@@ -17,9 +17,9 @@
   S2(S2 &s2) : a(s2.a) {}
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/parallel_sections_reduction_messages.cpp b/clang/test/OpenMP/parallel_sections_reduction_messages.cpp
index 05cc7f0f..26b3a53 100644
--- a/clang/test/OpenMP/parallel_sections_reduction_messages.cpp
+++ b/clang/test/OpenMP/parallel_sections_reduction_messages.cpp
@@ -26,9 +26,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/sections_lastprivate_messages.cpp b/clang/test/OpenMP/sections_lastprivate_messages.cpp
index 5f6b420..01bb13d 100644
--- a/clang/test/OpenMP/sections_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/sections_lastprivate_messages.cpp
@@ -17,9 +17,9 @@
   S2(S2 &s2) : a(s2.a) {}
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/sections_reduction_messages.cpp b/clang/test/OpenMP/sections_reduction_messages.cpp
index f13c5b3..58b22a5 100644
--- a/clang/test/OpenMP/sections_reduction_messages.cpp
+++ b/clang/test/OpenMP/sections_reduction_messages.cpp
@@ -27,9 +27,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/simd_lastprivate_messages.cpp b/clang/test/OpenMP/simd_lastprivate_messages.cpp
index 16223db..349d6a5 100644
--- a/clang/test/OpenMP/simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/simd_lastprivate_messages.cpp
@@ -17,9 +17,9 @@
   S2(S2 &s2) : a(s2.a) {}
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/simd_reduction_messages.cpp b/clang/test/OpenMP/simd_reduction_messages.cpp
index 1e1a233..bdf429d 100644
--- a/clang/test/OpenMP/simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/simd_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_parallel_for_lastprivate_messages.cpp b/clang/test/OpenMP/target_parallel_for_lastprivate_messages.cpp
index c001b7f..ee703a1 100644
--- a/clang/test/OpenMP/target_parallel_for_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_parallel_for_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   S2 &operator=(const S2 &);
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_parallel_for_reduction_messages.cpp b/clang/test/OpenMP/target_parallel_for_reduction_messages.cpp
index 234b71a..9f1f68f 100644
--- a/clang/test/OpenMP/target_parallel_for_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_parallel_for_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_parallel_for_simd_lastprivate_messages.cpp b/clang/test/OpenMP/target_parallel_for_simd_lastprivate_messages.cpp
index 51fc724..b41dc87 100644
--- a/clang/test/OpenMP/target_parallel_for_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_parallel_for_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   S2 &operator=(const S2 &);
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_parallel_for_simd_reduction_messages.cpp b/clang/test/OpenMP/target_parallel_for_simd_reduction_messages.cpp
index 289b5b2..72e2130 100644
--- a/clang/test/OpenMP/target_parallel_for_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_parallel_for_simd_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_parallel_reduction_messages.cpp b/clang/test/OpenMP/target_parallel_reduction_messages.cpp
index 52338ee..038f099 100644
--- a/clang/test/OpenMP/target_parallel_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_parallel_reduction_messages.cpp
@@ -24,9 +24,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_simd_lastprivate_messages.cpp b/clang/test/OpenMP/target_simd_lastprivate_messages.cpp
index afb38d9..9a6eb24 100644
--- a/clang/test/OpenMP/target_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   S2 &operator=(const S2 &);
   const S2 &operator=(const S2 &) const;
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_simd_reduction_messages.cpp b/clang/test/OpenMP/target_simd_reduction_messages.cpp
index ca14acb..9e1bb05 100644
--- a/clang/test/OpenMP/target_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_simd_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_lastprivate_messages.cpp b/clang/test/OpenMP/target_teams_distribute_lastprivate_messages.cpp
index 8d594e9..5cfe782 100644
--- a/clang/test/OpenMP/target_teams_distribute_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_parallel_for_lastprivate_messages.cpp b/clang/test/OpenMP/target_teams_distribute_parallel_for_lastprivate_messages.cpp
index d31acef..ccecb63 100644
--- a/clang/test/OpenMP/target_teams_distribute_parallel_for_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_parallel_for_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_parallel_for_reduction_messages.cpp b/clang/test/OpenMP/target_teams_distribute_parallel_for_reduction_messages.cpp
index ba9586a..59b3541 100644
--- a/clang/test/OpenMP/target_teams_distribute_parallel_for_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_parallel_for_reduction_messages.cpp
@@ -19,9 +19,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_lastprivate_messages.cpp b/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_lastprivate_messages.cpp
index 954830e..7f17d67 100644
--- a/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_reduction_messages.cpp b/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_reduction_messages.cpp
index cadccbf..63744c7 100644
--- a/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_parallel_for_simd_reduction_messages.cpp
@@ -19,9 +19,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_reduction_messages.cpp b/clang/test/OpenMP/target_teams_distribute_reduction_messages.cpp
index d52ee07..3cfb086 100644
--- a/clang/test/OpenMP/target_teams_distribute_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_reduction_messages.cpp
@@ -24,9 +24,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_simd_lastprivate_messages.cpp b/clang/test/OpenMP/target_teams_distribute_simd_lastprivate_messages.cpp
index 3b533e2..b8b1916 100644
--- a/clang/test/OpenMP/target_teams_distribute_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_distribute_simd_reduction_messages.cpp b/clang/test/OpenMP/target_teams_distribute_simd_reduction_messages.cpp
index 1c02832..35d4e12 100644
--- a/clang/test/OpenMP/target_teams_distribute_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_teams_distribute_simd_reduction_messages.cpp
@@ -19,9 +19,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/target_teams_reduction_messages.cpp b/clang/test/OpenMP/target_teams_reduction_messages.cpp
index 48fa3102..b5876b10 100644
--- a/clang/test/OpenMP/target_teams_reduction_messages.cpp
+++ b/clang/test/OpenMP/target_teams_reduction_messages.cpp
@@ -24,9 +24,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/taskgroup_task_reduction_messages.cpp b/clang/test/OpenMP/taskgroup_task_reduction_messages.cpp
index 9c8177b..819dc5b 100644
--- a/clang/test/OpenMP/taskgroup_task_reduction_messages.cpp
+++ b/clang/test/OpenMP/taskgroup_task_reduction_messages.cpp
@@ -24,9 +24,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/taskloop_lastprivate_messages.cpp b/clang/test/OpenMP/taskloop_lastprivate_messages.cpp
index e436444..1d238ea 100644
--- a/clang/test/OpenMP/taskloop_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/taskloop_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/taskloop_reduction_messages.cpp b/clang/test/OpenMP/taskloop_reduction_messages.cpp
index 7295075..23f70b5 100644
--- a/clang/test/OpenMP/taskloop_reduction_messages.cpp
+++ b/clang/test/OpenMP/taskloop_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/taskloop_simd_lastprivate_messages.cpp b/clang/test/OpenMP/taskloop_simd_lastprivate_messages.cpp
index ed1bdf5..e5cba6c 100644
--- a/clang/test/OpenMP/taskloop_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/taskloop_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/taskloop_simd_reduction_messages.cpp b/clang/test/OpenMP/taskloop_simd_reduction_messages.cpp
index f9739f7..886b685 100644
--- a/clang/test/OpenMP/taskloop_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/taskloop_simd_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_lastprivate_messages.cpp b/clang/test/OpenMP/teams_distribute_lastprivate_messages.cpp
index b892141..6941197 100644
--- a/clang/test/OpenMP/teams_distribute_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_parallel_for_lastprivate_messages.cpp b/clang/test/OpenMP/teams_distribute_parallel_for_lastprivate_messages.cpp
index 5691af7..c5f457a 100644
--- a/clang/test/OpenMP/teams_distribute_parallel_for_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_parallel_for_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_parallel_for_reduction_messages.cpp b/clang/test/OpenMP/teams_distribute_parallel_for_reduction_messages.cpp
index 7366161..889efd7 100644
--- a/clang/test/OpenMP/teams_distribute_parallel_for_reduction_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_parallel_for_reduction_messages.cpp
@@ -19,9 +19,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_parallel_for_simd_lastprivate_messages.cpp b/clang/test/OpenMP/teams_distribute_parallel_for_simd_lastprivate_messages.cpp
index fce59b9..62f8559 100644
--- a/clang/test/OpenMP/teams_distribute_parallel_for_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_parallel_for_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_parallel_for_simd_reduction_messages.cpp b/clang/test/OpenMP/teams_distribute_parallel_for_simd_reduction_messages.cpp
index 47494b9..b0522e8 100644
--- a/clang/test/OpenMP/teams_distribute_parallel_for_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_parallel_for_simd_reduction_messages.cpp
@@ -19,9 +19,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_reduction_messages.cpp b/clang/test/OpenMP/teams_distribute_reduction_messages.cpp
index d0a6d29..f11236f 100644
--- a/clang/test/OpenMP/teams_distribute_reduction_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp b/clang/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp
index 4c715bf..8bdb380 100644
--- a/clang/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp
@@ -18,9 +18,9 @@
   const S2 &operator =(const S2&) const;
   S2 &operator =(const S2&);
   static float S2s; // expected-note {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note {{static data member is predetermined as shared}}
 };
-const float S2::S2sc = 0; // expected-note {{static data member is predetermined as shared}}
+const float S2::S2sc = 0;
 const S2 b;
 const S2 ba[5];
 class S3 {
diff --git a/clang/test/OpenMP/teams_distribute_simd_reduction_messages.cpp b/clang/test/OpenMP/teams_distribute_simd_reduction_messages.cpp
index 879ec68..09d22bd 100644
--- a/clang/test/OpenMP/teams_distribute_simd_reduction_messages.cpp
+++ b/clang/test/OpenMP/teams_distribute_simd_reduction_messages.cpp
@@ -19,9 +19,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {
diff --git a/clang/test/OpenMP/teams_reduction_messages.cpp b/clang/test/OpenMP/teams_reduction_messages.cpp
index 9974c14..7aef977 100644
--- a/clang/test/OpenMP/teams_reduction_messages.cpp
+++ b/clang/test/OpenMP/teams_reduction_messages.cpp
@@ -25,9 +25,9 @@
   S2() : a(0) {}
   S2(S2 &s2) : a(s2.a) {}
   static float S2s; // expected-note 2 {{static data member is predetermined as shared}}
-  static const float S2sc;
+  static const float S2sc; // expected-note 2 {{'S2sc' declared here}}
 };
-const float S2::S2sc = 0; // expected-note 2 {{'S2sc' defined here}}
+const float S2::S2sc = 0;
 S2 b;                     // expected-note 3 {{'b' defined here}}
 const S2 ba[5];           // expected-note 2 {{'ba' defined here}}
 class S3 {