[clangd] Re-land "support outgoing calls in call hierarchy" (#117673)
[llvm-project.git] / flang / test / Semantics / OpenMP / nested01.f90
blob0936e4c1b45a5db4c437dd896d47b5a70a2c432c
1 ! RUN: %python %S/../test_errors.py %s %flang -fopenmp
3 ! Check OpenMP 2.17 Nesting of Regions
5 N = 1024
6 !$omp do
7 do i = 1, N
8 !ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
9 !$omp do
10 do j = 1, N
11 a = 3.14
12 enddo
13 enddo
15 !$omp do
16 do i = 1, N
17 !$omp target
18 do k = 1,N
19 !ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
20 !$omp do
21 do j = 1, N
22 a = 3.14
23 enddo
24 enddo
25 !$omp end target
26 enddo
28 !$omp do
29 do i = 1, N
30 !ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
31 !$omp scope
32 !$omp end scope
33 end do
34 !$omp end do
36 !$omp do
37 do i = 1, N
38 !$omp parallel
39 do k = 1,N
40 !$omp do
41 do j = 1, N
42 a = 3.14
43 enddo
44 enddo
45 !$omp end parallel
46 enddo
47 end