OSDN Git Service

* config/i386/i386.md (UNSPEC_VSIBADDR): New.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gfortran.dg / select_type_14.f03
1 ! { dg-do run }
2
3 ! PR fortran/44047
4 ! Double free happened, check that it works now.
5
6 ! Contributed by Janus Weil, janus@gcc.gnu.org.
7
8 implicit none
9 type t0
10  integer :: j = 42
11 end type t0
12 type t
13  integer :: i
14  class(t0), allocatable :: foo
15 end type t
16 type(t) :: m
17 allocate(t0 :: m%foo)
18 m%i = 5
19 select type(bar => m%foo)
20 type is(t0)
21  print *, bar
22  if (bar%j /= 42) call abort ()
23 end select
24 end