view gcc/testsuite/gfortran.dg/pdt_9.f03 @ 118:fd00160c1b76

ifdef TARGET_64BIT
author mir3636
date Tue, 27 Feb 2018 15:01:35 +0900
parents 04ced10e8804
children
line wrap: on
line source

! { dg-do compile }
!
! Test the fix for PR82168 in which the declarations for 'a'
! and 'b' threw errors even though they are valid.
!
! Contributed by  <physiker@toast2.net>
!
module mod
  implicit none
  integer, parameter :: dp = kind (0.0d0)
  type, public :: v(z, k)
    integer, len :: z
    integer, kind :: k = kind(0.0)
    real(kind = k) :: e(z)
  end type v
end module mod

program bug
  use mod
  implicit none
  type (v(2)) :: a     ! Missing parameter replaced by initializer.
  type (v(z=:, k=dp)), allocatable :: b ! Keyword was not working for '*' or ':'
end program bug