[Bug c++/92451] New: [10 Regression] ICE: Segmentation fault (in add_candidates)

asolokha at gmx dot com gcc-bugzilla@gcc.gnu.org
Mon Nov 11 07:33:00 GMT 2019


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92451

            Bug ID: 92451
           Summary: [10 Regression] ICE: Segmentation fault (in
                    add_candidates)
           Product: gcc
           Version: 10.0
            Status: UNCONFIRMED
          Keywords: error-recovery, ice-on-invalid-code
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: asolokha at gmx dot com
  Target Milestone: ---

g++-10.0.0-alpha20191110 snapshot (r278028) ICEs when compiling the following
testcase reduced from test/CXX/temp/temp.deduct.guide/p3.cpp from the clang
9.0.0 testsuite:

template<typename T> struct Local {};
void f() {
  Local(int);
}

% g++-10.0.0-alpha20191110 -std=c++17 -c dlhpwdpu.cpp
dlhpwdpu.cpp: In function 'void f()':
dlhpwdpu.cpp:3:12: error: class template argument deduction failed:
    3 |   Local(int);
      |            ^
dlhpwdpu.cpp:3:12: internal compiler error: Segmentation fault
0xe81bf0 crash_signal
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/toplev.c:329
0x7ec36a add_candidates
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/call.c:5772
0x7f20d2 add_candidates
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/call.c:5696
0x7f20d2 perform_overload_resolution
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/call.c:4461
0x7f57ea build_new_function_call(tree_node*, vec<tree_node*, va_gc,
vl_embed>**, int)
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/call.c:4535
0x950b30 do_class_deduction
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/pt.c:28070
0x950b30 do_auto_deduction(tree_node*, tree_node*, tree_node*, int,
auto_deduction_context, tree_node*, int)
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/pt.c:28118
0x9c07cf build_functional_cast(tree_node*, tree_node*, int)
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/typeck2.c:2270
0x8e8a9f cp_parser_functional_cast
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:29182
0x8fed45 cp_parser_postfix_expression
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:7122
0x8e40a7 cp_parser_binary_expression
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:9480
0x8e4f7f cp_parser_assignment_expression
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:9780
0x8e520c cp_parser_expression
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:9948
0x8e8685 cp_parser_expression_statement
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:11599
0x8f32b5 cp_parser_statement
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:11395
0x8f4785 cp_parser_statement_seq_opt
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:11742
0x8f4852 cp_parser_compound_statement
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:11696
0x9098cf cp_parser_function_body
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:22866
0x9098cf cp_parser_ctor_initializer_opt_and_function_body
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:22917
0x90ca15 cp_parser_function_definition_after_declarator
       
/var/tmp/portage/sys-devel/gcc-10.0.0_alpha20191110/work/gcc-10-20191110/gcc/cp/parser.c:28586


More information about the Gcc-bugs mailing list