https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103284
Bug ID: 103284
Summary: ICE in get_unique_type_string, at fortran/class.c:502
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: [email protected]
Target Milestone: ---
Affects versions down to at least r5, with a missing
attribute allocatable or pointer (follow-up of pr95980) :
$ cat z1.f90
program p
type t
character :: c
end type
class(t) :: x
select type (y => x)
end select
end
$ gfortran-12-20211114 -c z1.f90
f951: internal compiler error: Segmentation fault
0xd5dbdf crash_signal
../../gcc/toplev.c:322
0x773317 get_unique_type_string
../../gcc/fortran/class.c:502
0x773d01 get_unique_hashed_string
../../gcc/fortran/class.c:524
0x7771a9 gfc_build_class_symbol(gfc_typespec*, symbol_attribute*,
gfc_array_spec**)
../../gcc/fortran/class.c:666
0x7cf373 gfc_match_select_type()
../../gcc/fortran/match.c:6433
0x7f35f4 match_word
../../gcc/fortran/parse.c:67
0x7f35f4 decode_statement
../../gcc/fortran/parse.c:430
0x7f4e2a next_free
../../gcc/fortran/parse.c:1397
0x7f4e2a next_statement
../../gcc/fortran/parse.c:1629
0x7f654b parse_spec
../../gcc/fortran/parse.c:4168
0x7f98ac parse_progunit
../../gcc/fortran/parse.c:6179
0x7fab91 gfc_parse_file()
../../gcc/fortran/parse.c:6724
0x84806f gfc_be_parse_file
../../gcc/fortran/f95-lang.c:216