golang/go

gccgo: internal compiler error in declare_function

dvyukov opened this issue · 2 comments

gccgo crashes on the following input:

package a
func(func())a(int)
go1: internal compiler error: in declare_function, at go/gofrontend/gogo.cc:1930
0x622169 Gogo::declare_function(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, Function_type*, Location)
    ../../gcc/go/gofrontend/gogo.cc:1930
0x647d98 Parse::function_decl(bool)
    ../../gcc/go/gofrontend/parse.cc:2306
0x648523 Parse::program()
    ../../gcc/go/gofrontend/parse.cc:5667
0x610411 go_parse_input_files(char const**, unsigned int, bool, bool)
    ../../gcc/go/gofrontend/go.cc:73
0x60c32f go_langhook_parse_file
    ../../gcc/go/go-lang.c:304

gcc version 6.0.0 2015070 (experimental) (GCC)

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