aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/coarray/alloc_comp_1.f90
blob: cf3ece2523b34cb2290acb8cb2e94dd8f72f8da7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
! { dg-do run }
!
! Allocatable scalar corrays were mishandled (ICE)
!
type t
  integer, allocatable :: caf[:]
end type t
type(t) :: a
allocate (a%caf[3:*])
a%caf = 7
if (a%caf /= 7) STOP 1
if (any (lcobound (a%caf) /= [ 3 ]) &
    .or. ucobound (a%caf, dim=1) /= num_images ()+2)  &
  STOP 2
deallocate (a%caf)
end