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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [module_function_type_1.f90] - Blame information for rev 694

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do compile }
2
! This checks the fix for PR33295 in which the A_type in initA was
3
! not promoted to module level and so not recognised as being the
4
! same as that emanating directly from module a.
5
!
6
! Contributed by Janus Weil 
7
!
8
module A
9
  type A_type
10
    real comp
11
  end type
12
end module A
13
 
14
module B
15
contains
16
  function initA()
17
    use A
18
    implicit none
19
    type(A_type):: initA
20
    initA%comp=1.0
21
  end function
22
end module B
23
 
24
program C
25
  use B
26
  use A
27
  implicit none
28
  type(A_type):: A_var
29
  A_var = initA()
30
end program C
31
 
32
! { dg-final { cleanup-modules "a b" } }
33
 

powered by: WebSVN 2.1.0

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