Skip to content

Commit 47fbdc4

Browse files
Add some more tests
1 parent 5d9be32 commit 47fbdc4

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

flang/test/Semantics/OpenMP/detach01.f90

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,16 @@ program detach01
3131
x = x + 1
3232
!$omp end task
3333

34+
!ERROR: A variable: `event_01` that appears in a DETACH clause cannot appear on FIRSTPRIVATE clause on the same construct
35+
!$omp task detach(event_01) firstprivate(event_01)
36+
x = x + 1
37+
!$omp end task
38+
39+
!ERROR: A variable: `event_01` that appears in a DETACH clause cannot appear on SHARED clause on the same construct
40+
!$omp task detach(event_01) shared(event_01)
41+
x = x + 1
42+
!$omp end task
43+
3444
!ERROR: A variable: `event_01` that appears in a DETACH clause cannot appear on IN_REDUCTION clause on the same construct
3545
!$omp task detach(event_01) in_reduction(+:event_01)
3646
x = x + 1

0 commit comments

Comments
 (0)