[Bug c++/90915] New: [9/10 Regression] ICE in has_attribute, at c-family/c-attribs.c:4221
gscfq@t-online.de
gcc-bugzilla@gcc.gnu.org
Tue Jun 18 16:30:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90915
Bug ID: 90915
Summary: [9/10 Regression] ICE in has_attribute, at
c-family/c-attribs.c:4221
Product: gcc
Version: 10.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: gscfq@t-online.de
Target Milestone: ---
Changed between 20181118 and 20181125 :
$ cat z1.cc
struct S;
template<int> struct T
{
static_assert (__builtin_has_attribute (((S *) 0) -> a, packed));
};
$ g++-10-20190616 -c z1.cc
z1.cc:4:53: warning: invalid use of incomplete type 'struct S'
4 | static_assert (__builtin_has_attribute (((S *) 0) -> a, packed));
| ^~
z1.cc:1:8: note: forward declaration of 'struct S'
1 | struct S;
| ^
z1.cc:4:59: internal compiler error: Segmentation fault
4 | static_assert (__builtin_has_attribute (((S *) 0) -> a, packed));
| ^~~~~~
0xb933cf crash_signal
../../gcc/toplev.c:326
0x7a1872 has_attribute(unsigned int, tree_node*, tree_node*, tree_node*
(*)(tree_node*))
../../gcc/c-family/c-attribs.c:4221
0x6c2d46 cp_parser_has_attribute_expression
../../gcc/cp/parser.c:8584
0x6c2d46 cp_parser_unary_expression
../../gcc/cp/parser.c:8192
0x69f43f cp_parser_cast_expression
../../gcc/cp/parser.c:9346
0x69fc12 cp_parser_binary_expression
../../gcc/cp/parser.c:9448
0x6a0989 cp_parser_assignment_expression
../../gcc/cp/parser.c:9745
0x6a037d cp_parser_constant_expression
../../gcc/cp/parser.c:10029
0x6a0662 cp_parser_static_assert
../../gcc/cp/parser.c:14449
0x6cb8bc cp_parser_member_declaration
../../gcc/cp/parser.c:24393
0x6aa58a cp_parser_member_specification_opt
../../gcc/cp/parser.c:24259
0x6aa58a cp_parser_class_specifier_1
../../gcc/cp/parser.c:23400
0x6ac181 cp_parser_class_specifier
../../gcc/cp/parser.c:23662
0x6ac181 cp_parser_type_specifier
../../gcc/cp/parser.c:17424
0x6acd64 cp_parser_decl_specifier_seq
../../gcc/cp/parser.c:14120
0x6c9dc5 cp_parser_single_declaration
../../gcc/cp/parser.c:28165
0x6ca14c cp_parser_template_declaration_after_parameters
../../gcc/cp/parser.c:27846
0x6ca757 cp_parser_explicit_template_declaration
../../gcc/cp/parser.c:28094
0x6ca757 cp_parser_template_declaration_after_export
../../gcc/cp/parser.c:28113
0x6cd2c9 cp_parser_declaration
../../gcc/cp/parser.c:13183
More information about the Gcc-bugs
mailing list