[clang] [llvm] Openmp 6.0 allow default clause on the target directive (PR #154942)
Shilei Tian via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 26 21:32:43 PDT 2025
================
@@ -0,0 +1,51 @@
+
+// RUN: %clang_cc1 -verify -fopenmp -fopenmp-version=60 -DOMP60 %s -Wuninitialized
+
+// RUN: %clang_cc1 -verify -fopenmp-simd -fopenmp-version=60 -DOMP60 %s -Wuninitialized
+
+// RUN: %clang_cc1 -verify -fopenmp -fopenmp-version=52 -DOMP52 %s -Wuninitialized
+
+void foo();
+
+namespace {
+static int y = 0;
+}
+static int x = 0;
+
+int main(int argc, char **argv) {
+#ifdef OMP60
+ #pragma omp target default // expected-error {{expected '(' after 'default'}}
----------------
shiltian wrote:
Can you remove the multiple white spaces between `target` and `default`, for all the cases here?
https://github.com/llvm/llvm-project/pull/154942
More information about the cfe-commits
mailing list