summaryrefslogtreecommitdiffstats
path: root/test/OpenMP/threadprivate_messages.cpp
diff options
context:
space:
mode:
authorAlp Toker <alp@nuanti.com>2013-12-18 19:10:54 +0000
committerAlp Toker <alp@nuanti.com>2013-12-18 19:10:54 +0000
commit7742deb9e03e5129dbe6148f5c9a55af73bd8535 (patch)
tree18f4da25252f1dc60e1d1c2e2f9687e90ed8488a /test/OpenMP/threadprivate_messages.cpp
parent7211ea47c1b502966ec02bb023fab59385caa591 (diff)
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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@197598 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/OpenMP/threadprivate_messages.cpp')
-rw-r--r--test/OpenMP/threadprivate_messages.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/OpenMP/threadprivate_messages.cpp b/test/OpenMP/threadprivate_messages.cpp
index 4858549a70..1665c48caf 100644
--- a/test/OpenMP/threadprivate_messages.cpp
+++ b/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}}