aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/pr102532.f90
blob: 714379a6ac27110be2688ec84979b6db443cb607 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
! { dg-do compile }
! { dg-options "-fcoarray=single" }
!
! Contributed by Gerhard Steinmetz  <gscfq@t-online.de>
!
subroutine foo
   character(:), allocatable :: x[:]
   associate (y => x(:)(2:)) ! { dg-error "Rank mismatch|deferred type parameter" }
   end associate
end

subroutine bar
   character(:), allocatable :: x[:]
   associate (y => x(:)(:)) ! { dg-error "Rank mismatch|deferred type parameter" }
   end associate
end