https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102434
Bug ID: 102434
Summary: [11/12 Regression] ICE in
output_constructor_regular_field, at varasm.c:5514
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: [email protected]
Target Milestone: ---
Started between 20201018 and 20201108 :
(derived from initlist-deduce3.C)
$ cat z1.cc
using size_t = decltype(sizeof 0);
namespace std {
template<typename T> union initializer_list {
const T *ptr;
size_t n;
};
}
template<typename T>
void Task() {}
auto b = { &Task<int> };
$ g++-12-20210919 -c z1.cc
z1.cc:10:24: internal compiler error: in output_constructor_regular_field, at
varasm.c:5514
10 | auto b = { &Task<int> };
| ^
0x1025b84 output_constructor_regular_field
../../gcc/varasm.c:5514
0x1025b84 output_constructor
../../gcc/varasm.c:5826
0x1025ecf output_constant
../../gcc/varasm.c:5172
0x1025ecf assemble_variable_contents
../../gcc/varasm.c:2235
0x102dcad assemble_variable(tree_node*, int, int, int)
../../gcc/varasm.c:2414
0x102ffaa varpool_node::assemble_decl()
../../gcc/varpool.c:595
0x96ac1f output_in_order
../../gcc/cgraphunit.c:2135
0x96ac1f symbol_table::compile()
../../gcc/cgraphunit.c:2353
0x96d54f symbol_table::compile()
../../gcc/cgraphunit.c:2540
0x96d54f symbol_table::finalize_compilation_unit()
../../gcc/cgraphunit.c:2537