#pragma omp parallel for ordered(2) // expected-note {{as specified in 'ordered' clause}}
foo();// expected-error {{expected 2 for loops after '#pragma omp parallel for'}}
returnargc;
}
intmain(intargc,char**argv){
#pragma omp parallel for ordered
for(inti=4;i<12;i++)
argv[0][i]=argv[0][i]-argv[0][i-4];
#pragma omp parallel for ordered( // expected-error {{expected expression}} expected-error {{expected ')'}} expected-note {{to match this '('}}
for(inti=4;i<12;i++)
argv[0][i]=argv[0][i]-argv[0][i-4];
#pragma omp parallel for ordered() // expected-error {{expected expression}}
for(inti=4;i<12;i++)
argv[0][i]=argv[0][i]-argv[0][i-4];
#pragma omp parallel for ordered(4 // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-note {{as specified in 'ordered' clause}}
for(inti=4;i<12;i++)
argv[0][i]=argv[0][i]-argv[0][i-4];// expected-error {{expected 4 for loops after '#pragma omp parallel for', but found only 1}}
#pragma omp parallel for ordered(2 + 2)) // expected-warning {{extra tokens at the end of '#pragma omp parallel for' are ignored}} expected-note {{as specified in 'ordered' clause}}
for(inti=4;i<12;i++)
argv[0][i]=argv[0][i]-argv[0][i-4];// expected-error {{expected 4 for loops after '#pragma omp parallel for', but found only 1}}
#pragma omp parallel for ordered(foobool(1) > 0 ? 1 : 2) // expected-error {{expression is not an integral constant expression}}
for(inti=4;i<12;i++)
argv[0][i]=argv[0][i]-argv[0][i-4];
// expected-error@+3 {{expression is not an integral constant expression}}
// expected-error@+2 2 {{directive '#pragma omp parallel for' cannot contain more than one 'ordered' clause}}