summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/gomp/pr36790.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.dg/gomp/pr36790.c')
-rw-r--r--gcc/testsuite/gcc.dg/gomp/pr36790.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/gomp/pr36790.c b/gcc/testsuite/gcc.dg/gomp/pr36790.c
new file mode 100644
index 000000000..b3379f156
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/gomp/pr36790.c
@@ -0,0 +1,23 @@
+/* PR middle-end/36790 */
+/* { dg-do compile } */
+/* { dg-options "-fopenmp" } */
+
+void
+foo (char b)
+{
+}
+
+void
+bar (char b)
+{
+ foo (b);
+ #pragma omp task default (shared)
+ b = 0;
+}
+
+int
+main ()
+{
+ bar (0);
+ return 0;
+}