[clang] [OpenMP] Allow OMP6.0 features. (PR #122108)
Michael Kruse via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 27 05:56:13 PST 2025
================
@@ -205,77 +262,134 @@ namespace {
}
#pragma omp end declare target
-#pragma omp declare target link(S) // expected-error {{'S' used in declare target directive is not a variable or a function name}}
+// expected-error at +1 {{'S' used in declare target directive is not a variable or a function name}}
+#pragma omp declare target link(S)
-#pragma omp declare target (x, x) // expected-error {{'x' appears multiple times in clauses on the same declare target directive}}
-#pragma omp declare target to(x) to(x) // omp45-error {{'x' appears multiple times in clauses on the same declare target directive}} omp5-error {{'x' appears multiple times in clauses on the same declare target directive}} omp51-error {{'x' appears multiple times in clauses on the same declare target directive}} omp52-error {{unexpected 'to' clause, use 'enter' instead}} omp52-error {{expected at least one 'enter', 'link' or 'indirect' clause}}
-#pragma omp declare target link(x) // expected-error {{'x' must not appear in both clauses 'to' and 'link'}}
+// expected-error at +1 {{'x' appears multiple times in clauses on the same declare target directive}}
+#pragma omp declare target (x, x)
+// omp52-error at +3 {{unexpected 'to' clause, use 'enter' instead}}
+// omp52-error at +2 {{expected at least one 'enter', 'link' or 'indirect' clause}}
+// omp45-to-51-clause-error at +1 {{'x' appears multiple times in clauses on the same declare target directive}}
----------------
Meinersbur wrote:
So much better 👍
https://github.com/llvm/llvm-project/pull/122108
More information about the cfe-commits
mailing list