[C++ PATCH] Deprecate -ffriend-injection
[official-gcc.git] / gcc / testsuite / gfortran.dg / linked_list_1.f90
blob8066bcb39548cd958cccd018786602ad0b16b070
1 ! { dg-do compile }
2 ! Regression. ICE on valid code.
3 ! The following worked with 4.1.3 and 4.2.2, but failed
4 ! (segmentation fault) with 4.3.0 because the type comparison
5 ! tried to comparethe types of the components of type(node), even
6 ! though the only component is of type(node).
8 ! Found using the Fortran Company Fortran 90 Test Suite (Lite),
9 ! Version 1.4
11 ! Reported by Tobias Burnus <burnus@gcc.gnu.org>
13 program error
14 implicit none
15 type node
16 sequence
17 type(node), pointer :: next
18 end type
19 type(node), pointer :: list
21 interface
22 subroutine insert(ptr)
23 implicit none
24 type node
25 sequence
26 type(node), pointer :: next
27 end type
28 type(node), pointer :: ptr
29 end subroutine insert
30 end interface
31 allocate (list);
32 end program error