aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/null_9.f90
blob: 7f28c53f4656eeba921689e6067c273da7c0a37f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
! { dg-do run }

MODULE fold_convert_loc_ice
  IMPLICIT NONE
  PRIVATE

  TYPE, PUBLIC :: ta
    PRIVATE
    INTEGER :: a_comp
  END TYPE ta

  TYPE, PUBLIC :: tb
    TYPE(ta), ALLOCATABLE :: b_comp
  END TYPE tb

  PUBLIC :: proc
CONTAINS
  SUBROUTINE proc
    TYPE(tb) :: b

    b = tb(null())
    if (allocated( b%b_comp )) STOP 1
  END SUBROUTINE proc
END MODULE fold_convert_loc_ice

  USE fold_convert_loc_ice

  call proc()
END