OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [use_allocated_1.f90] - Diff between revs 149 and 154

Only display areas with differences | Details | Blame | View Log

Rev 149 Rev 154
! { dg-do run }
! { dg-do run }
! PR17678
! PR17678
! We were incorrectly setting use-associated variables to unallocated
! We were incorrectly setting use-associated variables to unallocated
! on procedure entry.
! on procedure entry.
module foo
module foo
  integer, dimension(:), allocatable :: bar
  integer, dimension(:), allocatable :: bar
end module
end module
program main
program main
  use foo
  use foo
  allocate (bar(10))
  allocate (bar(10))
  call init
  call init
end program main
end program main
subroutine init
subroutine init
  use foo
  use foo
  if (.not.allocated(bar)) call abort
  if (.not.allocated(bar)) call abort
end subroutine init
end subroutine init
! { dg-final { cleanup-modules "foo" } }
! { dg-final { cleanup-modules "foo" } }
 
 

powered by: WebSVN 2.1.0

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