summaryrefslogtreecommitdiff
path: root/flang/test/Semantics/OpenMP/private-is-pointer-allocatable-check.f90
blob: 7b3915d9a1104f58b5d07f1274ba75c061ce920b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
! RUN: %flang_fc1 -fopenmp -fsyntax-only %s

subroutine s
  integer, pointer :: p
  integer, target :: t
  real(4), allocatable :: arr

  !$omp parallel private(p)
    p=>t
  !$omp end parallel

  allocate(arr)
  !$omp parallel private(arr)
  if (.not. allocated(arr)) then
     print *, 'not allocated'
  endif
  !$omp end parallel
end subroutine