
The PR139793 added handling of the Fortran-only "workshare" directive, however there are more such directives, e.g. "allocators". Use the genDirectiveLanguages function to detect non-C/C++ directives instead of enumerating them.
13 lines
541 B
C
13 lines
541 B
C
// RUN: %clang_cc1 -verify -fopenmp -ferror-limit 100 -o - %s
|
|
|
|
// Test the reaction to some Fortran-only directives.
|
|
|
|
void foo() {
|
|
#pragma omp allocators // expected-error {{expected an OpenMP directive}}
|
|
#pragma omp do // expected-error {{expected an OpenMP directive}}
|
|
#pragma omp end workshare // expected-error {{expected an OpenMP directive}}
|
|
#pragma omp parallel workshare // expected-warning {{extra tokens at the end of '#pragma omp parallel' are ignored}}
|
|
#pragma omp workshare // expected-error {{expected an OpenMP directive}}
|
|
}
|
|
|