https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96024
Bug ID: 96024 Summary: [9/10/11 Regression] ICE in mio_name_expr_t, at fortran/module.c:2159 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: --- This invalid code (character char(n) is not a legal len value) gives an ICE down to r6, seems to be accepted by r5 : $ cat z1.f90 module m type t character(char(1)) :: a end type type(t) :: z = t('a') end $ gfortran-5 -c z1.f90 $ $ gfortran-11-20200628 -c z1.f90 f951: internal compiler error: Segmentation fault 0xbd215f crash_signal ../../gcc/toplev.c:328 0x696d8c mio_name_expr_t ../../gcc/fortran/module.c:2159 0x696d8c mio_expr ../../gcc/fortran/module.c:3567 0x697543 mio_charlen ../../gcc/fortran/module.c:2629 0x69763c mio_typespec ../../gcc/fortran/module.c:2687 0x696da0 mio_expr ../../gcc/fortran/module.c:3586 0x697543 mio_charlen ../../gcc/fortran/module.c:2629 0x69763c mio_typespec ../../gcc/fortran/module.c:2687 0x6979c5 mio_component ../../gcc/fortran/module.c:2920 0x6989da mio_component_list ../../gcc/fortran/module.c:2957 0x6989da mio_symbol ../../gcc/fortran/module.c:4416 0x698e3d write_symbol ../../gcc/fortran/module.c:5771 0x698fa2 write_symbol0 ../../gcc/fortran/module.c:5811 0x698f18 write_symbol0 ../../gcc/fortran/module.c:5790 0x698f18 write_symbol0 ../../gcc/fortran/module.c:5790 0x69bb04 write_module ../../gcc/fortran/module.c:6153 0x69bb04 dump_module ../../gcc/fortran/module.c:6283 0x69becd gfc_dump_module(char const*, int) ../../gcc/fortran/module.c:6340 0x6b5d26 gfc_parse_file() ../../gcc/fortran/parse.c:6457 0x7016ff gfc_be_parse_file ../../gcc/fortran/f95-lang.c:212