1! { dg-do compile } 2! 3! PR 50227: [4.7 Regression] [OOP] ICE-on-valid with allocatable class variable 4! 5! Contributed by Andrew Benson <abenson@caltech.edu> 6 7module G_Nodes 8 private 9 10 type, public :: t0 11 end type 12 13 type, public, extends(t0) :: t1 14 end type 15 16contains 17 18 function basicGet(self) 19 implicit none 20 class(t0), pointer :: basicGet 21 class(t0), target, intent(in) :: self 22 select type (self) 23 type is (t1) 24 basicGet => self 25 end select 26 end function basicGet 27 28end module G_Nodes 29