1 // RUN: %clang_cc1 -verify -fopenmp -ferror-limit 100 %s
3 // RUN: %clang_cc1 -verify -fopenmp-simd -ferror-limit 100 %s
9 #pragma omp barrier allocate(argc) // expected-error {{unexpected OpenMP clause 'allocate' in directive '#pragma omp barrier'}}
10 #pragma omp barrier untied // expected-error {{unexpected OpenMP clause 'untied' in directive '#pragma omp barrier'}}
11 #pragma omp barrier unknown // expected-warning {{extra tokens at the end of '#pragma omp barrier' are ignored}}
13 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
18 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
23 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
30 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
33 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
41 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
48 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
53 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
61 int main(int argc
, char **argv
) {
64 #pragma omp barrier untied // expected-error {{unexpected OpenMP clause 'untied' in directive '#pragma omp barrier'}}
65 #pragma omp barrier unknown // expected-warning {{extra tokens at the end of '#pragma omp barrier' are ignored}}
67 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
72 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
77 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
84 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
87 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
95 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
102 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}
107 #pragma omp barrier // expected-error {{'#pragma omp barrier' cannot be an immediate substatement}}