summaryrefslogtreecommitdiff
path: root/flang/test/Semantics/OpenMP/resolve01.f90
blob: 79b67885b8b9c7fbe597506593e27c82863173bf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
! RUN: %python %S/../test_errors.py %s %flang -fopenmp

! 2.4 An array section designates a subset of the elements in an array. Although
! Substring shares similar syntax but cannot be treated as valid array section.

  character*8 c, b
  character a

  b = "HIFROMPGI"
  c = b(2:7)
  !ERROR: Substrings are not allowed on OpenMP directives or clauses
  !$omp parallel private(c(1:3))
  a = c(1:1)
  !$omp end parallel
end