https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108606
Bug ID: 108606 Summary: [13 Regression] ICE in potential_constant_expression_1, at cp/constexpr.cc:9713 Product: gcc Version: 13.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Started between 20220925 and 20221009 : $ cat z1.cc void f() { g([&](auto x) { class C { friend void h(); }; } } $ g++-13-20230129 -c z1.cc z1.cc: In lambda function: z1.cc:6:3: internal compiler error: in potential_constant_expression_1, at cp/constexpr.cc:9713 6 | } | ^ 0x7efa5b potential_constant_expression_1 ../../gcc/cp/constexpr.cc:9712 0x7ee09a potential_constant_expression_1 ../../gcc/cp/constexpr.cc:9281 0x7eeb5e potential_constant_expression_1 ../../gcc/cp/constexpr.cc:9303 0x7ee09a potential_constant_expression_1 ../../gcc/cp/constexpr.cc:9281 0x7ee09a potential_constant_expression_1 ../../gcc/cp/constexpr.cc:9281 0x7efdda potential_constant_expression_1(tree_node*, bool, bool, bool, bool, int) ../../gcc/cp/constexpr.cc:10027 0x83868c finish_function(bool) ../../gcc/cp/decl.cc:18200 0x8666e4 finish_lambda_function(tree_node*) ../../gcc/cp/lambda.cc:1807 0x8e5df9 cp_parser_lambda_body ../../gcc/cp/parser.cc:11827 0x8e5df9 cp_parser_lambda_expression ../../gcc/cp/parser.cc:11148 0x8e5df9 cp_parser_primary_expression ../../gcc/cp/parser.cc:5826 0x8e9056 cp_parser_postfix_expression ../../gcc/cp/parser.cc:7777 0x8fc5df cp_parser_unary_expression ../../gcc/cp/parser.cc:9141 0x8d118f cp_parser_cast_expression ../../gcc/cp/parser.cc:10045 0x8d1a4f cp_parser_binary_expression ../../gcc/cp/parser.cc:10147 0x8d2454 cp_parser_assignment_expression ../../gcc/cp/parser.cc:10490 0x8d63bf cp_parser_parenthesized_expression_list_elt ../../gcc/cp/parser.cc:8110 0x8d6885 cp_parser_parenthesized_expression_list ../../gcc/cp/parser.cc:8579 0x8e88e0 cp_parser_postfix_expression ../../gcc/cp/parser.cc:7854 0x8fc5df cp_parser_unary_expression ../../gcc/cp/parser.cc:9141