https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96086
Bug ID: 96086 Summary: ICE in gfc_match_select_rank, at fortran/match.c:6645 Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Affects versions r10/r11, with a missing attribute allocatable/pointer : $ cat z1.f90 subroutine s class(*) :: x(..) select rank (y => x) end select end $ cat z2.f90 subroutine s type t end type class(t) :: x(..) select rank (y => x) end select end $ cat z3.f90 program p class(*) :: x(..) select rank (y => x) end select end $ gfortran-11-20200705 -c z1.f90 f951: internal compiler error: Segmentation fault 0xbd3bdf crash_signal ../../gcc/toplev.c:328 0x69083d gfc_match_select_rank() ../../gcc/fortran/match.c:6645 0x6af35e match_word ../../gcc/fortran/parse.c:65 0x6af35e decode_statement ../../gcc/fortran/parse.c:429 0x6b0b6a next_free ../../gcc/fortran/parse.c:1280 0x6b0b6a next_statement ../../gcc/fortran/parse.c:1512 0x6b21bb parse_spec ../../gcc/fortran/parse.c:3923 0x6b4f8c parse_progunit ../../gcc/fortran/parse.c:5852 0x6b6a4c gfc_parse_file() ../../gcc/fortran/parse.c:6400 0x70284f gfc_be_parse_file ../../gcc/fortran/f95-lang.c:212