1!RUN: %S/test_errors.sh %s %t %f18 -fopenmp
2! OpenMP Version 4.5
3! 2.15.3.1 default Clause
4program omp_default
5  integer :: a(10), b(10), c(10),i,k
6  !ERROR: At most one DEFAULT clause can appear on the PARALLEL directive
7  !$omp parallel default(shared), default(private)
8  do i = 1, 10
9    c(i) = a(i) + b(i) + k
10  end do
11  !$omp end parallel
12
13  !ERROR: At most one DEFAULT clause can appear on the TASK directive
14  !$omp task default(shared), default(none), shared(a,b,c,k,i)
15  do i = 1, 10
16    c(i) = a(i) + b(i) + k
17  end do
18  !$omp end task
19
20  !ERROR: At most one DEFAULT clause can appear on the TASKLOOP directive
21  !$omp taskloop default(shared), default(private)
22  do i = 1, 10
23    c(i) = a(i) + b(i) + k
24  end do
25  !$omp end taskloop
26
27  !ERROR: At most one DEFAULT clause can appear on the TEAMS directive
28  !$omp teams default(shared), default(none), shared(i,a,b,k,c)
29  do i = 1, 10
30    c(i) = a(i) + b(i) + k
31  end do
32  !$omp end teams
33
34end program omp_default
35