https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71196
Bug ID: 71196 Summary: f951: internal compiler error: in gfc_conv_string_init, at fortran/trans-const.c:149 Product: gcc Version: 6.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: georg.bugzilla at gmx dot at Target Milestone: --- Created attachment 38525 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38525&action=edit minimal self contained sourcce for reproduction of the ICE gfortran -v ------------------------------------ Using built-in specs. COLLECT_GCC=/tmp/gcc-6/bin/gfortran COLLECT_LTO_WRAPPER=/tmp/gcc-6/libexec/gcc/x86_64-pc-linux-gnu/6.1.0/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: ../gcc-6.1.0/configure --prefix=/tmp/gcc-6/ --enable-languages=c,c++,fortran Thread model: posix gcc version 6.1.0 (GCC) ------------------------------------ gfortran -Wall -Wextra -c ice.f90 with ice.f90 (attached) ------------------------------------ module ice type substructure_ integer :: id character(16) :: value end type substructure_ type structure_ type(substructure_) :: element end type structure_ type(structure_) :: structure DATA structure%element%id / 1 / DATA structure%element%value / "test" / end module ice ------------------------------------ results in ------------------------------------ f951: internal compiler error: in gfc_conv_string_init, at fortran/trans-const.c:149 0x6cfaba gfc_conv_string_init(tree_node*, gfc_expr*) ../../gcc-6.1.0/gcc/fortran/trans-const.c:149 0x6ecaff gfc_conv_initializer(gfc_expr*, gfc_typespec*, tree_node*, bool, bool, bool) ../../gcc-6.1.0/gcc/fortran/trans-expr.c:6731 0x6ecd8b gfc_conv_structure(gfc_se*, gfc_expr*, int) ../../gcc-6.1.0/gcc/fortran/trans-expr.c:7458 0x6ecb4a gfc_conv_initializer(gfc_expr*, gfc_typespec*, tree_node*, bool, bool, bool) ../../gcc-6.1.0/gcc/fortran/trans-expr.c:6724 0x6ecd8b gfc_conv_structure(gfc_se*, gfc_expr*, int) ../../gcc-6.1.0/gcc/fortran/trans-expr.c:7458 0x6ecb4a gfc_conv_initializer(gfc_expr*, gfc_typespec*, tree_node*, bool, bool, bool) ../../gcc-6.1.0/gcc/fortran/trans-expr.c:6724 0x6d80ec gfc_get_symbol_decl(gfc_symbol*) ../../gcc-6.1.0/gcc/fortran/trans-decl.c:1689 0x6da253 gfc_create_module_variable ../../gcc-6.1.0/gcc/fortran/trans-decl.c:4667 0x6a345b do_traverse_symtree ../../gcc-6.1.0/gcc/fortran/symbol.c:3817 0x6dcc7b gfc_generate_module_vars(gfc_namespace*) ../../gcc-6.1.0/gcc/fortran/trans-decl.c:5110 0x6bb44b gfc_generate_module_code(gfc_namespace*) ../../gcc-6.1.0/gcc/fortran/trans.c:2032 0x6741dd translate_all_program_units ../../gcc-6.1.0/gcc/fortran/parse.c:5600 0x6741dd gfc_parse_file() ../../gcc-6.1.0/gcc/fortran/parse.c:5819 0x6b5365 gfc_be_parse_file ../../gcc-6.1.0/gcc/fortran/f95-lang.c:201 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <http://gcc.gnu.org/bugs.html> for instructions. ------------------------------------