diff options
Diffstat (limited to 'test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp')
-rw-r--r-- | test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp b/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp index 4c715bf2ce30..51dbfef22933 100644 --- a/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp +++ b/test/OpenMP/teams_distribute_simd_lastprivate_messages.cpp @@ -18,14 +18,14 @@ public: 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 { int a; - S3 &operator=(const S3 &s3); // expected-note 2 {{implicitly declared private here}} + S3 &operator=(const S3 &s3); // expected-note {{implicitly declared private here}} public: S3() : a(0) {} @@ -52,7 +52,7 @@ public: }; class S6 { int a; - S6() : a(0) {} + S6() : a(0) {} // expected-note {{implicitly declared private here}} public: S6(const S6 &s6) : a(s6.a) {} @@ -255,12 +255,14 @@ int main(int argc, char **argv) { #pragma omp teams distribute simd lastprivate(j) for (i = 0; i < argc; ++i) foo(); +// expected-error@+2 {{firstprivate variable cannot be lastprivate}} expected-note@+2 {{defined as firstprivate}} #pragma omp target -#pragma omp teams distribute simd firstprivate(m) lastprivate(m) // expected-error {{'operator=' is a private member of 'S3'}} +#pragma omp teams distribute simd firstprivate(m) lastprivate(m) for (i = 0; i < argc; ++i) foo(); +// expected-error@+2 {{lastprivate variable cannot be firstprivate}} expected-note@+2 {{defined as lastprivate}} #pragma omp target -#pragma omp teams distribute simd lastprivate(n) firstprivate(n) // OK +#pragma omp teams distribute simd lastprivate(n) firstprivate(n) // expected-error {{calling a private constructor of class 'S6'}} for (i = 0; i < argc; ++i) foo(); static int si; |