[flang] Accept polymorphic component element in storage_size
[llvm-project.git] / flang / test / Semantics / OpenMP / omp-do-cycle.f90
blobb6617acb0794a6379a49df5ed224d2be06d5881a
1 ! RUN: %python %S/../test_errors.py %s %flang -fopenmp
2 ! OpenMP Version 4.5
3 ! Check for cycle statements leaving an OpenMP structured block
5 program omp_do
6 integer i, j, k
8 !$omp parallel
9 foo: do i = 0, 10
10 !$omp do
11 bar: do j = 0, 10
12 !ERROR: CYCLE to construct 'foo' outside of DO construct is not allowed
13 cycle foo
14 end do bar
15 !$omp end do
16 end do foo
17 !$omp end parallel
19 foo1: do i = 0, 10
20 !$omp parallel
21 foo2: do k = 0, 10
22 !$omp do
23 foo3: do j = 0, 10
24 !ERROR: CYCLE to construct 'foo1' outside of PARALLEL construct is not allowed
25 !ERROR: CYCLE to construct 'foo1' outside of DO construct is not allowed
26 cycle foo1
27 end do foo3
28 !$omp end do
29 end do foo2
30 !$omp end parallel
31 end do foo1
33 bar1: do i = 0, 10
34 !$omp parallel
35 bar2: do k = 0, 10
36 bar3: do j = 0, 10
37 !ERROR: CYCLE to construct 'bar1' outside of PARALLEL construct is not allowed
38 cycle bar1
39 end do bar3
40 end do bar2
41 !$omp end parallel
42 end do bar1
44 end program omp_do