This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/86551] New: [ICE] bare class and select type
- From: "daanvanvugt at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 17 Jul 2018 15:04:59 +0000
- Subject: [Bug fortran/86551] New: [ICE] bare class and select type
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86551
Bug ID: 86551
Summary: [ICE] bare class and select type
Product: gcc
Version: 8.1.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: daanvanvugt at gmail dot com
Target Milestone: ---
The following program produces an internal compiler error for me.
module a
type, abstract :: t1
end type
type, extends(t1) :: t2
end type
contains
subroutine b
implicit none
class(t1) :: c2
select type (d => c2)
end select type
end subroutine b
end module a
Removing the select type statement gives the expected error:
a.f90:9:19:
class(t1) :: c2
1
Error: CLASS variable ‘c2’ at (1) must be dummy, allocatable or pointer
Adding allocatable or pointer attributes fixes the ICE.