[Bug fortran/58233] null pointer cm in gfc_conv_structure at fortran/trans-expr.c:6132

zeccav at gmail dot com gcc-bugzilla@gcc.gnu.org
Fri Apr 24 17:25:00 GMT 2015


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58233

--- Comment #3 from Vittorio Zecca <zeccav at gmail dot com> ---
Still there on 4.9.2 at trans-expr.c:6193

if (!c->expr || (cm->attr.allocatable && cm->attr.flavor != FL_PROCEDURE))

/home/vitti/gcc-4.9.2-sanitize/test/f951 p.f
 MAIN__
p.f:1:0: internal compiler error: in gfc_conv_structure, at
fortran/trans-expr.c:6193
       type t
 ^
0x7c45c2 gfc_conv_structure(gfc_se*, gfc_expr*, int)
    ../../gcc-4.9.2/gcc/fortran/trans-expr.c:6193
0x7c20c0 gfc_conv_initializer(gfc_expr*, gfc_typespec*, tree_node*, bool, bool,
bool)
    ../../gcc-4.9.2/gcc/fortran/trans-expr.c:5718
0x78e78f gfc_get_symbol_decl(gfc_symbol*)
    ../../gcc-4.9.2/gcc/fortran/trans-decl.c:1540
0x7a0846 generate_local_decl
    ../../gcc-4.9.2/gcc/fortran/trans-decl.c:4847
0x726945 do_traverse_symtree
    ../../gcc-4.9.2/gcc/fortran/symbol.c:3630
0x726a73 gfc_traverse_ns(gfc_namespace*, void (*)(gfc_symbol*))
    ../../gcc-4.9.2/gcc/fortran/symbol.c:3655
0x7a178d generate_local_vars
    ../../gcc-4.9.2/gcc/fortran/trans-decl.c:5019
0x7a38ce gfc_generate_function_code(gfc_namespace*)
    ../../gcc-4.9.2/gcc/fortran/trans-decl.c:5595
0x75761d gfc_generate_code(gfc_namespace*)
    ../../gcc-4.9.2/gcc/fortran/trans.c:1945
0x6a2737 translate_all_program_units
    ../../gcc-4.9.2/gcc/fortran/parse.c:4953
0x6a2ebd gfc_parse_file()
    ../../gcc-4.9.2/gcc/fortran/parse.c:5150
0x7392c6 gfc_be_parse_file
    ../../gcc-4.9.2/gcc/fortran/f95-lang.c:212
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.

Compiling

type t
integer g
end type
type(t) :: u=t(1)
data u%g /2/ ! should emit diagnostic here
end



More information about the Gcc-bugs mailing list