[Bug c++/84653] New: internal compiler error: Segmentation fault (prep_operand)
vegard.nossum at gmail dot com
gcc-bugzilla@gcc.gnu.org
Thu Mar 1 17:18:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84653
Bug ID: 84653
Summary: internal compiler error: Segmentation fault
(prep_operand)
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
constexpr int a();
b(int, __attribute__((c(int{} && (a == (auto) (a);)))));
Output:
xgcc -x c++ -S -
<stdin>:2:50: error: expected ')' before ';' token
<stdin>:2:50: internal compiler error: Segmentation fault
0x3155789 crash_signal
/home/vegard/git/gcc/gcc/toplev.c:325
0x8b8a00 prep_operand
/home/vegard/git/gcc/gcc/cp/call.c:5404
0x9460d6 build_new_op_1
/home/vegard/git/gcc/gcc/cp/call.c:5651
0x948c36 build_new_op(unsigned int, tree_code, int, tree_node*, tree_node*,
tree_node*, tree_node**, int)
/home/vegard/git/gcc/gcc/cp/call.c:6058
0x1395e6b build_x_binary_op(unsigned int, tree_code, tree_node*, tree_code,
tree_node*, tree_code, tree_node**, int)
/home/vegard/git/gcc/gcc/cp/typeck.c:4030
0xec7b2b cp_parser_binary_expression
/home/vegard/git/gcc/gcc/cp/parser.c:9354
0xec95aa cp_parser_assignment_expression
/home/vegard/git/gcc/gcc/cp/parser.c:9484
0xed75e4 cp_parser_parenthesized_expression_list
/home/vegard/git/gcc/gcc/cp/parser.c:7762
0xeda0bb cp_parser_gnu_attribute_list
/home/vegard/git/gcc/gcc/cp/parser.c:25047
0xeda0bb cp_parser_gnu_attributes_opt
/home/vegard/git/gcc/gcc/cp/parser.c:24962
0xf8bfc7 cp_parser_decl_specifier_seq
/home/vegard/git/gcc/gcc/cp/parser.c:13429
0xfbab4d cp_parser_parameter_declaration
/home/vegard/git/gcc/gcc/cp/parser.c:21497
0xfbd49a cp_parser_parameter_declaration_list
/home/vegard/git/gcc/gcc/cp/parser.c:21309
0xfc0130 cp_parser_parameter_declaration_clause
/home/vegard/git/gcc/gcc/cp/parser.c:21230
0xf5c19f cp_parser_direct_declarator
/home/vegard/git/gcc/gcc/cp/parser.c:19983
0xfa24a8 cp_parser_declarator
/home/vegard/git/gcc/gcc/cp/parser.c:19857
0xfa277e cp_parser_init_declarator
/home/vegard/git/gcc/gcc/cp/parser.c:19383
0xfa9757 cp_parser_simple_declaration
/home/vegard/git/gcc/gcc/cp/parser.c:13063
0xfaf948 cp_parser_block_declaration
/home/vegard/git/gcc/gcc/cp/parser.c:12881
0x1002c05 cp_parser_declaration
/home/vegard/git/gcc/gcc/cp/parser.c:12778
$ xgcc --version
xgcc (GCC) 8.0.1 20180301 (experimental)
Built from git c435a9e730c6e8f10da09d58b4fc9aaeb401b0d5 (r258097).
It seems to be present in 4.9.0 if you pass -std=c++14.
Test case was minimised by C-Reduce.
More information about the Gcc-bugs
mailing list