https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84218
Bug ID: 84218 Summary: [8 Regression] ICE in free_expr0, at fortran/expr.c:451 Product: gcc Version: 8.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Another testcase (from scratch) with undefined variable "j". Changed between 20170820 and 20170910 : $ cat z1.f90 program p integer :: i character(3) :: x data (x(j:i), i=1,2,2) /'a'/ print *, x end $ gfortran-8-20170820 -c z1.f90 z1.f90:4:28: data (x(j:i), i=1,2,2) /'a'/ 1 Warning: Unused initialization string at (1) because variable has zero length $ gfortran-8-20180204 -c z1.f90 *** Error in `.../x86_64-pc-linux-gnu/8.0.1/f951': double free or corruption (out): 0x0000000003f1fdd0 *** ... z1.f90:6:0: end internal compiler error: Aborted 0xb953ff crash_signal ../../gcc/toplev.c:325 0x6a70c7 free_expr0 ../../gcc/fortran/expr.c:451 0x6a717d gfc_free_expr(gfc_expr*) ../../gcc/fortran/expr.c:520 0x738566 gfc_free_symbol(gfc_symbol*) ../../gcc/fortran/symbol.c:3042 0x7386f3 free_sym_tree ../../gcc/fortran/symbol.c:3890 0x7386ea free_sym_tree ../../gcc/fortran/symbol.c:3888 0x738391 gfc_free_namespace(gfc_namespace*) ../../gcc/fortran/symbol.c:4045 0x73897c gfc_symbol_done_2() ../../gcc/fortran/symbol.c:4089 0x6dca58 gfc_done_2() ../../gcc/fortran/misc.c:267 0x6fffc6 translate_all_program_units ../../gcc/fortran/parse.c:6140 0x6fffc6 gfc_parse_file() ../../gcc/fortran/parse.c:6324 0x74686f gfc_be_parse_file ../../gcc/fortran/f95-lang.c:204