diff options
author | Alp Toker <alp@nuanti.com> | 2013-12-18 19:10:54 +0000 |
---|---|---|
committer | Alp Toker <alp@nuanti.com> | 2013-12-18 19:10:54 +0000 |
commit | b14a4709f5d77de17bfaac68fde2d341bfc9e801 (patch) | |
tree | 6459fad549f8a5bff719d6bcd0d8abe21c1f162b /clang/test/OpenMP/threadprivate_messages.cpp | |
parent | d751fa7868db4a3c522c508900692f743bce8185 (diff) | |
download | bcm5719-llvm-b14a4709f5d77de17bfaac68fde2d341bfc9e801.tar.gz bcm5719-llvm-b14a4709f5d77de17bfaac68fde2d341bfc9e801.zip |
Fix OpenMP recovery with trailing tokens following the pragma
The recovery was failing due to a missing case in SkipUntil().
Also add back tests from r197553 that were reverted in the previous commit.
llvm-svn: 197598
Diffstat (limited to 'clang/test/OpenMP/threadprivate_messages.cpp')
-rw-r--r-- | clang/test/OpenMP/threadprivate_messages.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/test/OpenMP/threadprivate_messages.cpp b/clang/test/OpenMP/threadprivate_messages.cpp index 4858549a703..1665c48cafb 100644 --- a/clang/test/OpenMP/threadprivate_messages.cpp +++ b/clang/test/OpenMP/threadprivate_messages.cpp @@ -24,6 +24,12 @@ int foo() { // expected-note {{declared here}} return (a); } +#pragma omp threadprivate (a) ( // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'a'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} +#pragma omp threadprivate (a) [ // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'a'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} +#pragma omp threadprivate (a) { // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'a'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} +#pragma omp threadprivate (a) ) // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'a'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} +#pragma omp threadprivate (a) ] // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'a'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} +#pragma omp threadprivate (a) } // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'a'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} #pragma omp threadprivate a // expected-error {{expected '(' after 'threadprivate'}} #pragma omp threadprivate(d // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-error {{'#pragma omp threadprivate' must precede all references to variable 'd'}} #pragma omp threadprivate(d)) // expected-error {{'#pragma omp threadprivate' must precede all references to variable 'd'}} expected-warning {{extra tokens at the end of '#pragma omp threadprivate' are ignored}} |