golang/go

gccgo: internal compiler error in insert

dvyukov opened this issue · 2 comments

gccgo crashes on the following program:

package a
const c = 0<<false
go1: internal compiler error: in insert, at go/gofrontend/gogo.cc:7955
0x61ff44 Statement_inserter::insert(Statement*)
    ../../gcc/go/gofrontend/gogo.cc:7955
0x5deead Binary_expression::do_flatten(Gogo*, Named_object*, Statement_inserter*)
    ../../gcc/go/gofrontend/expressions.cc:5172
0x610913 Expression::flatten(Gogo*, Named_object*, Statement_inserter*)
    ../../gcc/go/gofrontend/expressions.h:813
0x610913 Flatten::expression(Expression**)
    ../../gcc/go/gofrontend/gogo.cc:3904
0x5e209d Expression::traverse(Expression**, Traverse*)
    ../../gcc/go/gofrontend/expressions.cc:43
0x616991 Named_constant::traverse_expression(Traverse*)
    ../../gcc/go/gofrontend/gogo.cc:6594
0x616991 Bindings::traverse(Traverse*, bool)
    ../../gcc/go/gofrontend/gogo.cc:7539
0x616b51 Gogo::traverse(Traverse*)
    ../../gcc/go/gofrontend/gogo.cc:2495
0x616daf Gogo::flatten()
    ../../gcc/go/gofrontend/gogo.cc:3938
0x6104db go_parse_input_files(char const**, unsigned int, bool, bool)
    ../../gcc/go/gofrontend/go.cc:139
0x60c20f go_langhook_parse_file
    ../../gcc/go/go-lang.c:304

gofrontend is on commit 1d9d92ab09996d2f7795481d2876a21194502b89

CL https://golang.org/cl/14645 mentions this issue.