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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [array_alloc_1.f90] - Blame information for rev 868

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
! PR 21104.  Make sure that either f() or its caller will allocate
2
! the array data.  We've decided to make the caller allocate it.
3
! { dg-do run }
4
program main
5
  implicit none
6
  call test (f ())
7
contains
8
  subroutine test (x)
9
    integer, dimension (10) :: x
10
    integer :: i
11
    do i = 1, 10
12
      if (x (i) .ne. i * 100) call abort
13
    end do
14
  end subroutine test
15
 
16
  function f ()
17
    integer, dimension (10) :: f
18
    integer :: i
19
    forall (i = 1:10) f (i) = i * 100
20
  end function f
21
end program main

powered by: WebSVN 2.1.0

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