The following testcase segfaults in 4.6: module module_myclass
implicit none type :: inner contains procedure :: set end type inner type :: myclass type(inner) :: slice end type myclass contains subroutine set(this) class(inner), intent(inout) :: this end subroutine set end module module_myclass module module_mysubclass use module_myclass, only : myclass implicit none type, extends(myclass) :: mysubclass contains procedure :: init end type mysubclass contains subroutine init(this) class(mysubclass), intent(inout) :: this call this%slice%set() ! XXX PROBLEM HERE this%slice not resolved end subroutine init end module module_mysubclass program test use module_mysubclass, only : mysubclass implicit none class(mysubclass), allocatable :: obs end program test -- Summary: ICE with file containing two modules and one program Product: gcc Version: 4.6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libfortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: pchwood at yahoo dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44064