https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102311
Bug ID: 102311 Summary: [11/12 Regression] ICE in gfc_enforce_clean_symbol_state, at fortran/symbol.c:4278 Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Changed between 20210822 and 20210905 : (gcc configured with --enable-checking=yes) $ cat z1.f90 module m contains function f() character(:), allocatable :: f character(1) :: g entry g() end end $ cat z2.f90 module m contains function f() character(:), allocatable :: f character(1) :: g f = 'f' entry g() g = 'g' end end $ gfortran-12-20210822 -c z1.f90 z1.f90:8:3: 8 | end | 1 Error: Entity 'master.0.f' at (1) has a deferred type parameter and requires either the POINTER or ALLOCATABLE attribute $ gfortran-12-20210905 -c z1.f90 z1.f90:3:3: 3 | function f() | 1 Error: Function f at (1) has entry g with mismatched characteristics z1.f90:3:3: 3 | function f() | 1 Error: Function f at (1) has entry g with mismatched characteristics f951: internal compiler error: in gfc_enforce_clean_symbol_state, at fortran/symbol.c:4278 0x8422f0 gfc_enforce_clean_symbol_state() ../../gcc/fortran/symbol.c:4278 0x7fd9bc next_statement ../../gcc/fortran/parse.c:1589 0x8034e4 gfc_parse_file() ../../gcc/fortran/parse.c:6638 0x8510ff gfc_be_parse_file ../../gcc/fortran/f95-lang.c:216