1 ! All of the following (up to PROGRAM) are okay:
5 subroutine sub_iterface()
6 !$omp assumes no_openmp_routines absent(simd) ! OK inferface of an external subroutine/subprogram
9 !$omp assumes no_openmp_routines absent(simd) ! OK external subroutine/subprogram
12 !$omp assumes no_parallelism absent(teams) ! OK internal subroutine/subprogram
16 integer function func ()
17 !$omp assumes no_openmp_routines absent(simd) ! OK external function/subprogram
19 integer function func_iterface()
20 !$omp assumes no_openmp_routines absent(simd) ! OK inferface of an external function/subprogram
25 integer function inner_func()
26 !$omp assumes no_parallelism absent(teams) ! OK internal function/subprogram
33 !$omp assumes contains(target) holds(x > 0.0)
36 subroutine mod_mod_sub_iterface()
37 !$omp assumes no_openmp_routines absent(simd) ! OK inferface of an external subroutine/subprogram
39 integer function mod_mod_func_iterface()
40 !$omp assumes no_openmp_routines absent(error) ! OK inferface of an external subroutine/subprogram
47 subroutine mod_sub_iterface()
48 !$omp assumes no_openmp_routines absent(simd) ! OK inferface of an external subroutine/subprogram
51 !$omp assumes no_openmp_routines absent(simd) ! OK module subroutine/subprogram
53 subroutine mod_inner_sub
54 !$omp assumes no_parallelism absent(teams) ! OK internal subroutine/subprogram
58 integer function mod_func ()
59 !$omp assumes no_openmp_routines absent(simd) ! OK module function/subprogram
61 integer function mod_func_iterface()
62 !$omp assumes no_openmp_routines absent(simd) ! OK inferface of an external function/subprogram
67 integer function mod_inner_func()
68 !$omp assumes no_parallelism absent(teams) ! OK internal function/subprogram
75 ! PROGRAM - invalid as:
76 ! main program is a program unit that is not a subprogram
77 !$omp assumes no_openmp absent(simd) ! { dg-error "must be in the specification part of a subprogram or module" }
80 !$omp assumes no_openmp absent(target) ! { dg-error "must be in the specification part of a subprogram or module" }