OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc2/] [gcc/] [testsuite/] [gfortran.dg/] [intent_out_5.f90] - Rev 384

Compare with Previous | Blame | View Log

! { dg-do run}
!
! PR fortran/41479
!
! Contributed by Juergen Reuter.
!
program main
 type :: container_t
    integer :: n = 42
    ! if the following line is omitted, the problem disappears
    integer, dimension(:), allocatable :: a
 end type container_t

 type(container_t) :: container

 if (container%n /= 42) call abort()
 if (allocated(container%a)) call abort()
 container%n = 1
 allocate(container%a(50))
 call init (container)
 if (container%n /= 42) call abort()
 if (allocated(container%a)) call abort()
contains
 subroutine init (container)
   type(container_t), intent(out) :: container
 end subroutine init
end program main

Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.