flang/test/Semantics/OpenACC/acc-resolve02.f90
raw| 1 | ! RUN: %python %S/../test_errors.py %s %flang -fopenacc |
| 2 | |
| 3 | subroutine compute() |
| 4 | integer :: a(3), c, i |
| 5 | |
| 6 | a = 1 |
| 7 | !ERROR: 'c' appears in more than one data-sharing clause on the same OpenACC directive |
| 8 | !$acc parallel firstprivate(c) private(c) |
| 9 | do i = 1, 3 |
| 10 | a(i) = c |
| 11 | end do |
| 12 | !$acc end parallel |
| 13 | end subroutine compute |
| 14 | |
| 15 | program mm |
| 16 | call compute() |
| 17 | end |