diff options
Diffstat (limited to 'test/OpenMP/parallel_sections_private_messages.cpp')
| -rw-r--r-- | test/OpenMP/parallel_sections_private_messages.cpp | 12 | 
1 files changed, 10 insertions, 2 deletions
| diff --git a/test/OpenMP/parallel_sections_private_messages.cpp b/test/OpenMP/parallel_sections_private_messages.cpp index e0b7488e5162..d9c4404bd984 100644 --- a/test/OpenMP/parallel_sections_private_messages.cpp +++ b/test/OpenMP/parallel_sections_private_messages.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -verify -fopenmp=libiomp5 %s +// RUN: %clang_cc1 -verify -fopenmp %s  void foo() {  } @@ -123,6 +123,14 @@ int foomain(I argc, C **argv) {    return 0;  } +namespace A { +double x; +#pragma omp threadprivate(x) // expected-note {{defined as threadprivate or thread local}} +} +namespace B { +using A::x; +} +  int main(int argc, char **argv) {    S4 e(4);    S5 g(5); @@ -172,7 +180,7 @@ int main(int argc, char **argv) {    {      foo();    } -#pragma omp parallel sections private(h) // expected-error {{threadprivate or thread local variable cannot be private}} +#pragma omp parallel sections private(h, B::x) // expected-error 2 {{threadprivate or thread local variable cannot be private}}    {      foo();    } | 
