12021-10-08 Jakub Jelinek <jakub@redhat.com> 2 3 Backported from master: 4 2021-10-08 Jakub Jelinek <jakub@redhat.com> 5 6 PR c++/102640 7 * parser.c (handle_omp_declare_target_clause): New function. 8 (cp_parser_omp_declare_target): Use it. 9 102021-10-07 Patrick Palka <ppalka@redhat.com> 11 12 Backported from master: 13 2021-10-07 Patrick Palka <ppalka@redhat.com> 14 15 PR c++/99904 16 * pt.c (is_compatible_template_arg): Set processing_template_decl 17 around tsubst_constraint_info. 18 192021-10-06 Patrick Palka <ppalka@redhat.com> 20 21 Backported from master: 22 2021-10-05 Patrick Palka <ppalka@redhat.com> 23 24 PR c++/102547 25 * constexpr.c (potential_constant_expression_1): Handle 26 NONTYPE_ARGUMENT_PACK. 27 282021-10-06 Patrick Palka <ppalka@redhat.com> 29 30 Backported from master: 31 2021-09-30 Patrick Palka <ppalka@redhat.com> 32 33 PR c++/102535 34 * method.c (is_xible_helper): Don't exit early for multi-arg 35 ctors in C++20. 36 372021-10-06 Patrick Palka <ppalka@redhat.com> 38 39 Backported from master: 40 2021-09-30 Patrick Palka <ppalka@redhat.com> 41 42 PR c++/95567 43 * method.c (build_comparison_op): Skip DECL_VIRTUAL_P fields. 44 452021-10-06 Patrick Palka <ppalka@redhat.com> 46 47 Backported from master: 48 2021-09-22 Patrick Palka <ppalka@redhat.com> 49 50 DR 2446 51 PR c++/102412 52 * constexpr.c (cxx_eval_constant_expression) 53 <case TEMPLATE_ID_EXPR>: Check value_dependent_expression_p 54 instead of processing_template_decl. 55 * pt.c (value_dependent_expression_p) <case TEMPLATE_ID_EXPR>: 56 Return true only if any_dependent_template_arguments_p. 57 (instantiation_dependent_r) <case CALL_EXPR>: Remove this case. 58 <case TEMPLATE_ID_EXPR>: Likewise. 59 602021-10-06 Patrick Palka <ppalka@redhat.com> 61 62 Backported from master: 63 2021-09-16 Patrick Palka <ppalka@redhat.com> 64 65 PR c++/98486 66 * constraint.cc (get_normalized_constraints_from_decl): Always 67 look up constraints using the most general template. 68 * decl.c (grokdeclarator): Set constraints on a static data 69 member template. 70 * pt.c (determine_specialization): Check constraints on a 71 variable template. 72 732021-10-06 Patrick Palka <ppalka@redhat.com> 74 75 Backported from master: 76 2021-09-14 Patrick Palka <ppalka@redhat.com> 77 78 PR c++/102163 79 * constexpr.c (cxx_eval_call_expression): After evaluating a 80 subobject constructor call for an empty union member, produce a 81 side effect that makes sure the member gets activated. 82 832021-10-06 Patrick Palka <ppalka@redhat.com> 84 85 Backported from master: 86 2021-08-18 Patrick Palka <ppalka@redhat.com> 87 88 PR c++/101344 89 PR c++/101803 90 * cp-tree.h (CONSTRUCTOR_BRACES_ELIDED_P): Define. 91 * decl.c (reshape_init_r): Set it. 92 * pt.c (collect_ctor_idx_types): Recurse into a sub-CONSTRUCTOR 93 iff CONSTRUCTOR_BRACES_ELIDED_P. 94 952021-10-06 Patrick Palka <ppalka@redhat.com> 96 97 Backported from master: 98 2021-08-18 Patrick Palka <ppalka@redhat.com> 99 100 PR c++/101883 101 * pt.c (convert_template_argument): Pass LOOKUP_IMPLICIT to 102 do_auto_deduction. 103 1042021-10-05 Jakub Jelinek <jakub@redhat.com> 105 106 Backported from master: 107 2021-10-05 Jakub Jelinek <jakub@redhat.com> 108 109 PR c++/102548 110 * tree.c (apply_identity_attributes): Fix handling of the 111 case where an attribute in the list doesn't affect type 112 identity but some attribute before it does. 113 1142021-10-05 Jakub Jelinek <jakub@redhat.com> 115 116 Backported from master: 117 2021-10-01 Jakub Jelinek <jakub@redhat.com> 118 119 PR c++/102496 120 * name-lookup.c (push_local_extern_decl_alias): Return early even for 121 tls vars with non-dependent type when processing_template_decl. For 122 CP_DECL_THREAD_LOCAL_P vars call set_decl_tls_model on alias. 123 1242021-10-03 Iain Sandoe <iain@sandoe.co.uk> 125 126 Backported from master: 127 2021-09-28 Iain Sandoe <iain@sandoe.co.uk> 128 129 PR c++/102454 130 * coroutines.cc (analyze_fn_parms): Clean up synthetic names for 131 unnamed function params. 132 (morph_fn_to_coro): Do not try to set a guard variable for param 133 DTORs in the ramp, unless we have exceptions active. 134 1352021-10-03 Iain Sandoe <iain@sandoe.co.uk> 136 137 Backported from master: 138 2021-09-14 Iain Sandoe <iain@sandoe.co.uk> 139 140 * coroutines.cc (struct param_info): Add copy_var. 141 (build_actor_fn): Use simplified param references. 142 (register_param_uses): Likewise. 143 (rewrite_param_uses): Likewise. 144 (analyze_fn_parms): New function. 145 (coro_rewrite_function_body): Add proxies for the fn 146 parameters to the outer bind scope of the rewritten code. 147 (morph_fn_to_coro): Use simplified version of param ref. 148 1492021-10-03 Iain Sandoe <iain@sandoe.co.uk> 150 151 Backported from master: 152 2021-09-14 Iain Sandoe <iain@sandoe.co.uk> 153 154 * coroutines.cc (coro_resume_fn_id, coro_destroy_fn_id, 155 coro_promise_id, coro_frame_needs_free_id, coro_resume_index_id, 156 coro_self_handle_id, coro_actor_continue_id, 157 coro_frame_i_a_r_c_id): New. 158 (coro_init_identifiers): Initialize new name identifiers. 159 (coro_promise_type_found_p): Use pre-built identifiers. 160 (struct await_xform_data): Remove unused fields. 161 (transform_await_expr): Delete code that is now unused. 162 (build_actor_fn): Simplify interface, use pre-built identifiers and 163 remove transforms that are no longer needed. 164 (build_destroy_fn): Use revised field names. 165 (register_local_var_uses): Use pre-built identifiers. 166 (coro_rewrite_function_body): Simplify interface, use pre-built 167 identifiers. Generate proxy vars in the outer bind expr scope for the 168 implementation state that we wish to expose. 169 (morph_fn_to_coro): Adjust comments for new variable names, use pre- 170 built identifiers. Remove unused code to generate frame entries for 171 the implementation state. Adjust call for build_actor_fn. 172 1732021-10-03 Iain Sandoe <iain@sandoe.co.uk> 174 175 Backported from master: 176 2021-09-03 Iain Sandoe <iain@sandoe.co.uk> 177 178 * coroutines.cc (register_local_var_uses): Do not mangle 179 frame entries for the outermost scope. Record the outer 180 scope as nesting depth 0. 181 1822021-10-03 Iain Sandoe <iain@sandoe.co.uk> 183 184 Backported from master: 185 2021-09-03 Iain Sandoe <iain@sandoe.co.uk> 186 187 * coroutines.cc (coro_build_artificial_var): New. 188 (build_actor_fn): Use var builder, rename vars to use 189 implementation namespace. 190 (coro_rewrite_function_body): Likewise. 191 (morph_fn_to_coro): Likewise. 192 1932021-10-03 Iain Sandoe <iain@sandoe.co.uk> 194 195 Backported from master: 196 2021-09-03 Iain Sandoe <iain@sandoe.co.uk> 197 198 * coroutines.cc (transform_local_var_uses): Record 199 frame offset expressions as DECL_VALUE_EXPRs instead of 200 rewriting them. 201 2022021-10-03 Iain Sandoe <iain@sandoe.co.uk> 203 204 Backported from master: 205 2021-09-01 Iain Sandoe <iain@sandoe.co.uk> 206 207 * coroutines.cc (build_actor_fn): Add begin/finish clauses 208 to the initial test in the actor function. 209 2102021-10-03 Iain Sandoe <iain@sandoe.co.uk> 211 212 Backported from master: 213 2021-09-01 Iain Sandoe <iain@sandoe.co.uk> 214 215 * coroutines.cc (await_statement_walker): Use build_stmt and 216 add_stmt instead of build1 and finish_expr_stmt. 217 2182021-10-03 Jason Merrill <jason@redhat.com> 219 220 Backported from master: 221 2021-05-07 Jason Merrill <jason@redhat.com> 222 223 * coroutines.cc (build_co_await): Don't call 'rvalue'. 224 (flatten_await_stmt): Simplify initialization. 225 (morph_fn_to_coro): Change 'rvalue' to 'move'. Simplify. 226 2272021-09-15 Jakub Jelinek <jakub@redhat.com> 228 229 Backported from master: 230 2021-09-15 Jakub Jelinek <jakub@redhat.com> 231 232 PR c++/88578 233 PR c++/102295 234 * typeck2.c (split_nonconstant_init_1): Don't throw away empty 235 initializers of flexible array members if they have non-zero type 236 size. 237 2382021-09-15 Jakub Jelinek <jakub@redhat.com> 239 240 Backported from master: 241 2021-09-14 Jakub Jelinek <jakub@redhat.com> 242 243 PR c++/102295 244 * decl.c (layout_var_decl): For aggregates ending with a flexible 245 array member, add the size of the initializer for that member to 246 DECL_SIZE and DECL_SIZE_UNIT. 247 2482021-09-15 Jakub Jelinek <jakub@redhat.com> 249 250 Backported from master: 251 2021-09-14 Jakub Jelinek <jakub@redhat.com> 252 253 PR c++/102305 254 * method.c (is_xible_helper): Call complete_type on to. 255 2562021-09-07 Jakub Jelinek <jakub@redhat.com> 257 258 Backported from master: 259 2021-09-07 Jakub Jelinek <jakub@redhat.com> 260 261 PR c++/100495 262 * constexpr.c (maybe_save_constexpr_fundef): Save body even for 263 constexpr deleting dtors. 264 (cxx_eval_call_expression): Don't use DECL_CLONED_FUNCTION for 265 deleting dtors. 266 2672021-08-12 Jakub Jelinek <jakub@redhat.com> 268 269 Backported from master: 270 2021-08-04 Jakub Jelinek <jakub@redhat.com> 271 272 PR c++/101759 273 * parser.c (cp_parser_default_argument): Temporarily override 274 parser->omp_declare_simd and parser->oacc_routine to NULL. 275 2762021-08-12 Patrick Palka <ppalka@redhat.com> 277 278 Backported from master: 279 2021-08-12 Patrick Palka <ppalka@redhat.com> 280 281 PR c++/101663 282 * constexpr.c (cxx_eval_store_expression): Handle the lval=true 283 case in the early exit code path for empty stores with mismatched 284 types. 285 2862021-08-11 Patrick Palka <ppalka@redhat.com> 287 288 Backported from master: 289 2021-08-11 Patrick Palka <ppalka@redhat.com> 290 291 PR c++/101725 292 DR 2082 293 * cp-tree.h (unevaluated_p): Return true for REQUIRES_EXPR. 294 * decl.c (local_variable_p_walkfn): Don't walk into unevaluated 295 operands. 296 * parser.c (cp_parser_primary_expression) <case CPP_NAME>: Never 297 reject uses of local variables in unevaluated contexts. 298 * tree.c (cp_walk_subtrees) <case REQUIRES_EXPR>: Increment 299 cp_unevaluated_operand. Use cp_walk_tree directly instead of 300 WALK_SUBTREE to avoid the goto. Use REQUIRES_EXPR_REQS instead 301 of TREE_OPERAND directly. 302 3032021-08-11 Patrick Palka <ppalka@redhat.com> 304 305 Backported from master: 306 2021-08-02 Patrick Palka <ppalka@redhat.com> 307 308 PR c++/100828 309 * logic.cc (formula::formula): Use emplace_back instead of 310 push_back. 311 (formula::branch): Insert a copy of m_current directly after 312 m_current instead of at the end of the list. 313 (formula::erase): Define. 314 (decompose_formula): Remove. 315 (decompose_antecedents): Remove. 316 (decompose_consequents): Remove. 317 (derive_proofs): Remove. 318 (max_problem_size): Remove. 319 (diagnose_constraint_size): Remove. 320 (subsumes_constraints_nonnull): Rewrite directly in terms of 321 decompose_clause and derive_proof, interleaving decomposition 322 with implication checking. Remove limit on constraint complexity. 323 Use formula::erase to free the current clause before moving on to 324 the next one. 325 3262021-07-28 Release Manager 327 328 * GCC 11.2.0 released. 329 3302021-07-21 Jakub Jelinek <jakub@redhat.com> 331 332 Backported from master: 333 2021-07-21 Jakub Jelinek <jakub@redhat.com> 334 335 PR c++/101516 336 * semantics.c (finish_omp_reduction_clause): Also call 337 complete_type_or_else and return true if it fails. 338 3392021-07-20 Iain Sandoe <iain@sandoe.co.uk> 340 341 Backported from master: 342 2021-07-19 Iain Sandoe <iain@sandoe.co.uk> 343 344 PR c++/95520 345 * coroutines.cc (struct coroutine_info): Add fields for 346 actor and destroy function decls. 347 (to_ramp): New. 348 (coro_get_ramp_function): New. 349 (coro_get_actor_function): New. 350 (coro_get_destroy_function): New. 351 (act_des_fn): Set up mapping between ramp, actor and 352 destroy functions. 353 (morph_fn_to_coro): Adjust interface to the builder for 354 helper function decls. 355 * cp-tree.h (DECL_ACTOR_FN, DECL_DESTROY_FN, DECL_RAMP_FN, 356 JOIN_STR): New. 357 * mangle.c (write_encoding): Handle coroutine helpers. 358 (write_unqualified_name): Handle lambda coroutine helpers. 359 3602021-07-20 Iain Sandoe <iain@sandoe.co.uk> 361 362 Backported from master: 363 2021-07-09 Iain Sandoe <iain@sandoe.co.uk> 364 365 * coroutines.cc (build_actor_fn): Move common code to 366 act_des_fn. 367 (build_destroy_fn): Likewise. 368 (act_des_fn): Build the void return here. Ensure that the 369 source location matches the original function. 370 3712021-07-20 Iain Sandoe <iain@sandoe.co.uk> 372 373 Backported from master: 374 2021-07-09 Iain Sandoe <iain@sandoe.co.uk> 375 376 * coroutines.cc 377 (coro_rewrite_function_body): Connect the replacement 378 function block to the block nest correctly. 379 3802021-07-18 Tobias Burnus <tobias@codesourcery.com> 381 382 Backported from master: 383 2021-05-04 Tobias Burnus <tobias@codesourcery.com> 384 385 * semantics.c (finish_omp_reduction_clause): Accept float + complex 386 for || and && reductions. 387 3882021-07-18 Jakub Jelinek <jakub@redhat.com> 389 390 Backported from master: 391 2021-07-15 Jakub Jelinek <jakub@redhat.com> 392 393 PR c++/101443 394 * cp-gimplify.c (cp_fold): For comparisons with NULLPTR_TYPE 395 operands, fold them right away to true or false. 396 3972021-07-16 Patrick Palka <ppalka@redhat.com> 398 399 Backported from master: 400 2021-07-16 Patrick Palka <ppalka@redhat.com> 401 402 PR c++/101233 403 * pt.c (alias_ctad_tweaks): Clear cp_unevaluated_operand for 404 substituting DECL_ARGUMENTS. 405 4062021-07-16 Patrick Palka <ppalka@redhat.com> 407 408 Backported from master: 409 2021-05-11 Patrick Palka <ppalka@redhat.com> 410 411 PR c++/100138 412 * constraint.cc (tsubst_constraint): Set up cp_unevaluated. 413 (satisfy_atom): Set up iloc_sentinel before calling 414 cxx_constant_value. 415 * pt.c (tsubst_pack_expansion): When returning a rebuilt pack 416 expansion, carry over PACK_EXPANSION_LOCAL_P and 417 PACK_EXPANSION_SIZEOF_P from the original pack expansion. 418 4192021-07-13 Patrick Palka <ppalka@redhat.com> 420 421 Backported from master: 422 2021-07-09 Patrick Palka <ppalka@redhat.com> 423 424 PR c++/101181 425 * constraint.cc (tsubst_requires_expr): Pass complain/in_decl to 426 add_extra_args. 427 * cp-tree.h (add_extra_args): Add complain/in_decl parameters. 428 * pt.c (build_extra_args): Make a copy of args. 429 (add_extra_args): Add complain/in_decl parameters. Enable the 430 code for handling the case where the extra arguments are 431 dependent. 432 (tsubst_pack_expansion): Pass complain/in_decl to 433 add_extra_args. 434 (tsubst_template_args): Handle missing template arguments. 435 (tsubst_expr) <case IF_STMT>: Pass complain/in_decl to 436 add_extra_args. 437 4382021-07-13 Patrick Palka <ppalka@redhat.com> 439 440 Backported from master: 441 2021-07-09 Patrick Palka <ppalka@redhat.com> 442 443 PR c++/101247 444 * pt.c (any_template_parm_r) <case TEMPLATE_DECL>: Just walk the 445 DECL_CONTEXT. 446 4472021-07-13 Patrick Palka <ppalka@redhat.com> 448 449 Backported from master: 450 2021-07-02 Patrick Palka <ppalka@redhat.com> 451 452 PR c++/101247 453 * pt.c (any_template_parm_r) <case TEMPLATE_DECL>: Rewrite to 454 use common_enclosing_class and to not depend on the TREE_TYPE 455 of outer levels pointing to the corresponding primary template. 456 4572021-07-13 Patrick Palka <ppalka@redhat.com> 458 459 Backported from master: 460 2021-07-01 Patrick Palka <ppalka@redhat.com> 461 462 PR c++/101194 463 * constexpr.c (cxx_eval_array_reference): When the element type 464 is an empty type and the corresponding element is omitted, just 465 return an empty CONSTRUCTOR instead of attempting value 466 initialization. 467 4682021-07-13 Patrick Palka <ppalka@redhat.com> 469 470 Backported from master: 471 2021-06-24 Patrick Palka <ppalka@redhat.com> 472 473 PR c++/98832 474 * pt.c (maybe_aggr_guide): Handle alias templates appropriately. 475 4762021-07-13 Patrick Palka <ppalka@redhat.com> 477 478 Backported from master: 479 2021-06-24 Patrick Palka <ppalka@redhat.com> 480 481 PR c++/101182 482 * constraint.cc (evaluate_requires_expr): Adjust function comment. 483 * cp-gimplify.c (cp_genericize_r) <case REQUIRES_EXPR>: Move to ... 484 (cp_fold) <case REQUIRES_EXPR>: ... here. 485 4862021-07-13 Patrick Palka <ppalka@redhat.com> 487 488 Backported from master: 489 2021-06-07 Patrick Palka <ppalka@redhat.com> 490 491 PR c++/100918 492 * parser.c (cp_parser_lookup_name): Check access of the lookup 493 result before we potentially adjust an injected-class-name to 494 its TEMPLATE_DECL. 495 4962021-07-13 Patrick Palka <ppalka@redhat.com> 497 498 Backported from master: 499 2021-05-26 Patrick Palka <ppalka@redhat.com> 500 501 PR c++/97420 502 * cvt.c (noexcept_conv_p): Remove redundant checks and simplify. 503 (fnptr_conv_p): Don't call non_reference. Use INDIRECT_TYPE_P 504 instead of TYPE_PTR_P. 505 * pt.c (convert_nontype_argument_function): Look through 506 implicit INDIRECT_REFs before calling strip_fnptr_conv. 507 5082021-07-09 Jason Merrill <jason@redhat.com> 509 510 PR c++/101098 511 * decl.c (function_requirements_equivalent_p): Only compare 512 trailing requirements on a specialization. 513 5142021-07-09 Jason Merrill <jason@redhat.com> 515 516 PR c++/100838 517 * call.c (convert_like_internal): Clear tf_no_cleanup when 518 recursing. 519 (build_user_type_conversion_1): Only add ck_rvalue if 520 LOOKUP_ONLYCONVERTING. 521 5222021-07-09 Jason Merrill <jason@redhat.com> 523 524 PR c++/86355 525 * pt.c (use_pack_expansion_extra_args_p): Don't compare 526 args from the same argument pack. 527 5282021-07-08 Marek Polacek <polacek@redhat.com> 529 530 Backported from master: 531 2021-07-08 Marek Polacek <polacek@redhat.com> 532 533 PR c++/101087 534 * cp-tree.h (unevaluated_p): New. 535 * except.c (check_noexcept_r): Use it. Don't walk into 536 unevaluated operands. 537 5382021-07-07 Jason Merrill <jason@redhat.com> 539 540 Revert: 541 2020-12-02 Jason Merrill <jason@redhat.com> 542 543 * decl.c (check_initializer): Also look through STMT_EXPR 544 and BIND_EXPR. 545 5462021-07-07 Jason Merrill <jason@redhat.com> 547 548 PR c++/101040 549 PR c++/97566 550 * class.c (is_empty_field): Handle null argument. 551 * constexpr.c (cxx_eval_bare_aggregate): Discard initializer 552 for empty field. 553 5542021-06-29 Marek Polacek <polacek@redhat.com> 555 556 Backported from master: 557 2021-06-26 Marek Polacek <polacek@redhat.com> 558 559 PR c++/100752 560 * parser.c (cp_parser_declarator): Pass flags down to 561 cp_parser_declarator. Also pass static_p/member_p. 562 5632021-06-23 Jakub Jelinek <jakub@redhat.com> 564 565 Backported from master: 566 2021-06-21 Jakub Jelinek <jakub@redhat.com> 567 568 PR inline-asm/100785 569 * typeck.c (cxx_mark_addressable): Diagnose trying to make 570 bit-fields addressable. 571 5722021-06-21 Jason Merrill <jason@redhat.com> 573 574 PR c++/101106 575 * decl.c (duplicate_decls): Condition note on return value of pedwarn. 576 5772021-06-17 Jakub Jelinek <jakub@redhat.com> 578 579 Backported from master: 580 2021-06-06 Jakub Jelinek <jakub@redhat.com> 581 582 PR c/100902 583 * parser.c (cp_parser_omp_target): Call c_omp_adjust_map_clauses 584 even when target is combined with other constructs. 585 5862021-06-17 Jason Merrill <jason@redhat.com> 587 588 * init.c (build_vec_init): Preserve the type of base. 589 5902021-06-16 Jason Merrill <jason@redhat.com> 591 592 PR c++/101078 593 * pt.c (tsubst_baselink): Update binfos in non-dependent case. 594 5952021-06-16 Jason Merrill <jason@redhat.com> 596 597 PR c++/101029 598 * init.c (build_vec_init): Shortcut [0] case. 599 6002021-06-10 Patrick Palka <ppalka@redhat.com> 601 602 Backported from master: 603 2021-06-10 Patrick Palka <ppalka@redhat.com> 604 605 PR c++/100946 606 * constraint.cc (normalize_placeholder_type_constraints): When 607 normalizing a non-templated return-type-requirement, add a dummy 608 level to initial_parms. 609 6102021-06-09 Marek Polacek <polacek@redhat.com> 611 612 Backported from master: 613 2021-06-08 Marek Polacek <polacek@redhat.com> 614 615 PR c++/100065 616 * decl.c (grokdeclarator): Store a value-dependent 617 explicit-specifier even for deduction guides. 618 6192021-06-08 Jason Merrill <jason@redhat.com> 620 621 PR c++/100963 622 * call.c (perfect_conversion_p): Check check_narrowing. 623 6242021-06-08 Jason Merrill <jason@redhat.com> 625 626 PR c++/91706 627 * semantics.c (baselink_for_fns): Fix BASELINK_BINFO. 628 6292021-06-08 Jason Merrill <jason@redhat.com> 630 631 * module.cc (duplicate_hash::hash): Comment out. 632 (trees_in::tree_value): Adjust loop counter. 633 6342021-06-07 Patrick Palka <ppalka@redhat.com> 635 636 Backported from master: 637 2021-06-03 Patrick Palka <ppalka@redhat.com> 638 639 PR c++/100862 640 * pt.c (set_current_access_from_decl): Move to ... 641 * class.c (set_current_access_from_decl): ... here. 642 (handle_using_decl): Use it to propagate the access of the 643 using-enum decl to the copy of the imported enumerator. 644 * cp-tree.h (set_current_access_from_decl): Declare. 645 * decl.c (build_enumerator): Simplify using make_temp_override 646 and set_current_access_from_decl. 647 6482021-06-07 Patrick Palka <ppalka@redhat.com> 649 650 Backported from master: 651 2021-06-04 Patrick Palka <ppalka@redhat.com> 652 653 PR c++/100102 654 * pt.c (tsubst_function_decl): Remove old code for reducing 655 args when it has excess levels. 656 6572021-06-01 Jason Merrill <jason@redhat.com> 658 659 PR c++/91859 660 * call.c (build_op_delete_call): Don't set CALL_FROM_NEW_OR_DELETE_P 661 for destroying delete. 662 * init.c (build_delete): Don't clobber before destroying delete. 663 6642021-06-01 Jason Merrill <jason@redhat.com> 665 666 PR c++/100797 667 PR c++/95719 668 * call.c (build_over_call): Adjust base_binfo in 669 resolves_to_fixed_type_p case. 670 6712021-05-31 Jakub Jelinek <jakub@redhat.com> 672 673 Backported from master: 674 2021-05-25 Jakub Jelinek <jakub@redhat.com> 675 676 PR c++/100666 677 * call.c (convert_arg_to_ellipsis): For expressions with NULLPTR_TYPE 678 and side-effects, temporarily disable -Wunused-result warning when 679 building COMPOUND_EXPR. 680 6812021-05-28 Patrick Palka <ppalka@redhat.com> 682 683 Backported from master: 684 2021-05-26 Patrick Palka <ppalka@redhat.com> 685 686 PR c++/100502 687 * typeck.c (finish_class_member_access_expr): Disable ahead 688 of time access checking during the member lookup. 689 6902021-05-20 Jason Merrill <jason@redhat.com> 691 692 PR c++/100489 693 * decl.c (reshape_init_class): Handle designator for 694 member of anonymous aggregate here. 695 * typeck2.c (process_init_constructor_record): Not here. 696 6972021-05-20 Andreas Krebbel <krebbel@linux.ibm.com> 698 699 Backported from master: 700 2021-05-18 Andreas Krebbel <krebbel@linux.ibm.com> 701 702 PR c++/100281 703 * cvt.c (cp_convert_to_pointer): Use the size of the target 704 pointer type. 705 * tree.c (cp_build_reference_type): Call 706 cp_build_reference_type_for_mode with VOIDmode. 707 (cp_build_reference_type_for_mode): Rename from 708 cp_build_reference_type. Add MODE argument and invoke 709 build_reference_type_for_mode. 710 (strip_typedefs): Use build_pointer_type_for_mode and 711 cp_build_reference_type_for_mode for pointers and references. 712 7132021-05-20 Jason Merrill <jason@redhat.com> 714 715 PR c++/100634 716 * pt.c (invalid_nontype_parm_type_p): Return true for COMPLEX_TYPE. 717 7182021-05-20 Jason Merrill <jason@redhat.com> 719 720 PR c++/100659 721 * cp-tree.h (CONST_DECL_USING_P): Check for null TREE_TYPE. 722 7232021-05-19 Jason Merrill <jason@redhat.com> 724 725 PR c++/100367 726 PR c++/96299 727 * method.c (genericize_spaceship): Use fold_build2 for scalar 728 operands. 729 7302021-05-19 Jason Merrill <jason@redhat.com> 731 732 PR c++/100261 733 * rtti.c (get_tinfo_decl_direct): Check TYPE_TRANSPARENT_AGGR. 734 7352021-05-19 Jason Merrill <jason@redhat.com> 736 737 PR c++/100372 738 * tree.c (strip_typedefs): Only look at the pattern of a 739 TYPE_PACK_EXPANSION if it's a type. 740 7412021-05-18 Jason Merrill <jason@redhat.com> 742 743 PR c++/100644 744 * call.c (perfect_candidate_p): An implicitly deleted move 745 is not perfect. 746 7472021-05-18 Jason Merrill <jason@redhat.com> 748 749 PR c++/100205 750 PR c++/93314 751 * cp-tree.h (cp_evaluated): Add reset parm to constructor. 752 * parser.c (cp_parser_constant_expression): Change 753 allow_non_constant_p to int. Use cp_evaluated. 754 (cp_parser_initializer_clause): Pass 2 to allow_non_constant_p. 755 * semantics.c (finish_id_expression_1): Don't mess with 756 cp_unevaluated_operand here. 757 7582021-05-03 Patrick Palka <ppalka@redhat.com> 759 760 Backported from master: 761 2021-05-03 Patrick Palka <ppalka@redhat.com> 762 763 PR c++/100362 764 * parser.c (cp_parser_class_head): Reinstate calls to pushclass 765 and popclass when parsing the base-clause that were removed in 766 r11-6815. 767 7682021-04-29 Jakub Jelinek <jakub@redhat.com> 769 770 Backported from master: 771 2021-04-29 Jakub Jelinek <jakub@redhat.com> 772 773 PR c++/100319 774 * semantics.c (finish_omp_clauses): Fix up check that variable 775 mentioned in detach clause doesn't appear in data-sharing clauses. 776 7772021-04-27 Patrick Palka <ppalka@redhat.com> 778 779 Backported from master: 780 2021-04-24 Patrick Palka <ppalka@redhat.com> 781 782 PR c++/89565 783 PR c++/93383 784 PR c++/95291 785 PR c++/99200 786 PR c++/99683 787 * pt.c (do_class_deduction): Punt if the initializer is 788 type-dependent. 789 7902021-04-27 Marek Polacek <polacek@redhat.com> 791 792 Backported from master: 793 2021-04-22 Marek Polacek <polacek@redhat.com> 794 795 PR c++/100161 796 * pt.c (tsubst_copy_and_build) <case PLUS_EXPR>: Test op0 and 797 op1 separately for value- or type-dependence. 798 7992021-04-27 Marek Polacek <polacek@redhat.com> 800 801 Backported from master: 802 2021-04-21 Marek Polacek <polacek@redhat.com> 803 804 PR c++/96380 805 * parser.c (cp_parser_enum_specifier): Don't allow defining 806 types in enum-base. 807 8082021-04-27 Jakub Jelinek <jakub@redhat.com> 809 810 * module.cc: Remove #error that triggers if DEV-PHASE is empty. 811 8122021-04-27 Release Manager 813 814 * GCC 11.1.0 released. 815 8162021-04-19 Marek Polacek <polacek@redhat.com> 817 818 PR c++/97536 819 * decl.c (grokvardecl): Given an error when a concept is not defined 820 at namespace scope. 821 8222021-04-16 Jakub Jelinek <jakub@redhat.com> 823 824 PR c++/100111 825 * constexpr.c (cxx_eval_store_expression): Don't add CONSTRUCTORs 826 for empty classes into *valp when types don't match even when *valp 827 is NULL. 828 8292021-04-16 Marek Polacek <polacek@redhat.com> 830 831 PR c++/99803 832 * decl.c (make_typename_type): Give an error and return when 833 name is is_overloaded_fn. 834 * parser.c (cp_parser_class_name): Don't check is_overloaded_fn 835 before calling make_typename_type. 836 8372021-04-16 Patrick Palka <ppalka@redhat.com> 838 839 PR c++/99700 840 * constexpr.c (reduced_constant_expression_p): For array 841 CONSTRUCTORs, use a dedicated loop that additionally verifies 842 the CONSTRUCTOR spans the entire array. 843 8442021-04-16 Jakub Jelinek <jakub@redhat.com> 845 846 PR c++/99850 847 * parser.c (cp_parser_constraint_requires_parens) <case CPP_DEREF>: 848 If lambda_p, return pce_ok instead of pce_maybe_postfix. 849 8502021-04-16 Jakub Jelinek <jakub@redhat.com> 851 852 PR c++/99833 853 * pt.c (extract_locals_r): When handling DECL_EXPR of a structured 854 binding, add to data.internal also all corresponding structured 855 binding decls. 856 8572021-04-16 Jason Merrill <jason@redhat.com> 858 859 PR c++/100079 860 * cp-tree.h (first_field): Declare. 861 * mangle.c (range_expr_nelts): New. 862 (write_expression): Improve class NTTP mangling. 863 * pt.c (get_template_parm_object): Clear TREE_HAS_CONSTRUCTOR. 864 * tree.c (zero_init_expr_p): Improve class NTTP handling. 865 * decl.c: Adjust comment. 866 8672021-04-15 Jason Merrill <jason@redhat.com> 868 869 PR c++/80456 870 * call.c (build_new_method_call_1): Check again for side-effects 871 with a volatile object. 872 8732021-04-15 Jason Merrill <jason@redhat.com> 874 875 PR c++/100101 876 PR c++/99583 877 * pt.c (find_parameter_packs_r) [FUNCTION_TYPE]: Walk into 878 TYPE_RAISES_EXCEPTIONS here. 879 * tree.c (cp_walk_subtrees): Not here. 880 8812021-04-15 Jason Merrill <jason@redhat.com> 882 883 PR c++/100091 884 PR c++/99478 885 * parser.c (cp_parser_default_type_template_argument): Set 886 parser->local_variables_forbidden_p. 887 8882021-04-15 Richard Sandiford <richard.sandiford@arm.com> 889 890 PR c++/98852 891 * typeck.c (merge_type_attributes_from): New function. 892 (cp_common_type): Use it for vector types. 893 8942021-04-14 Jason Merrill <jason@redhat.com> 895 896 PR c++/100078 897 PR c++/93085 898 * pt.c (uses_outer_template_parms): Also look at default 899 template argument. 900 9012021-04-14 Jason Merrill <jason@redhat.com> 902 903 PR c++/93314 904 * semantics.c (finish_id_expression_1): Clear cp_unevaluated_operand 905 for a non-static data member in a constant-expression. 906 9072021-04-14 Patrick Palka <ppalka@redhat.com> 908 909 PR c++/83476 910 PR c++/99885 911 * pt.c (deducible_expression): Look through implicit 912 INDIRECT_REFs as well. 913 9142021-04-14 Jason Merrill <jason@redhat.com> 915 916 PR c++/99478 917 * parser.c (cp_parser_lambda_expression): Reject lambda 918 in template parameter type. 919 9202021-04-14 Jason Merrill <jason@redhat.com> 921 922 PR c++/90674 923 * decl.c (duplicate_decls): Don't propagate 924 DECL_INITIALIZED_IN_CLASS_P to a specialization. 925 9262021-04-14 Jason Merrill <jason@redhat.com> 927 928 PR c++/88742 929 PR c++/49951 930 PR c++/58123 931 * semantics.c (set_cleanup_locs): New. 932 (do_poplevel): Call it. 933 * parser.c (cp_parser_compound_statement): Consume the } 934 before finish_compound_stmt. 935 9362021-04-13 Jason Merrill <jason@redhat.com> 937 938 PR c++/100032 939 * pt.c (get_underlying_template): Compare TYPE_QUALS. 940 9412021-04-13 Jason Merrill <jason@redhat.com> 942 943 PR c++/100054 944 PR c++/90479 945 * init.c (get_nsdmi): Do more context adjustment for local classes. 946 9472021-04-13 Patrick Palka <ppalka@redhat.com> 948 949 PR c++/99008 950 * pt.c (do_class_deduction): Reject alias CTAD in C++17 mode 951 rather than issuing a pedwarn. 952 * typeck2.c (build_functional_cast_1): Handle CTAD uniformly 953 for consistent diagnostics. 954 9552021-04-13 Jason Merrill <jason@redhat.com> 956 957 PR c++/91933 958 * class.c (build_base_path): Shortcut simple non-pointer case. 959 9602021-04-13 Eric Botcazou <ebotcazou@adacore.com> 961 962 * module.cc (ordinary_loc_of): Test LINEMAPS_MACRO_LOWEST_LOCATION 963 of the linemap. 964 (module_state::write_location): Likewise. 965 9662021-04-13 Patrick Palka <ppalka@redhat.com> 967 968 PR c++/97134 969 * pt.c (do_class_deduction): Look through EXPR_PACK_EXPANSION 970 when checking if the initializer is an equivalent class 971 placeholder template parameter. 972 9732021-04-13 Patrick Palka <ppalka@redhat.com> 974 975 PR c++/99961 976 PR c++/99994 977 * constraint.cc (satisfy_normalized_constraints): Set 978 cp_unevaluated. 979 * parser.c (cp_parser_concept_definition): Likewise. 980 (cp_parser_requires_clause_opt): Likewise. 981 9822021-04-12 Jason Merrill <jason@redhat.com> 983 984 PR c++/93085 985 * pt.c (uses_outer_template_parms): Handle non-type and template 986 template parameters specifically. 987 9882021-04-11 Jason Merrill <jason@redhat.com> 989 990 PR c++/97974 991 * decl.c (fixup_anonymous_aggr): Prune all functions from 992 CLASSTYPE_MEMBER_VEC. 993 9942021-04-10 Jason Merrill <jason@redhat.com> 995 996 PR c++/98800 997 PR c++/97399 998 * parser.c (cp_parser_direct_declarator): Don't 999 inject_this_parameter if static_p. 1000 (cp_parser_omp_var_list_no_open): Parse 'this' even if 1001 current_class_ptr isn't set for a better diagnostic. 1002 10032021-04-10 Jason Merrill <jason@redhat.com> 1004 1005 PR c++/99180 1006 PR c++/93295 1007 PR c++/93867 1008 PR c++/99118 1009 PR c++/96873 1010 * pt.c (alias_ctad_tweaks): Handle failure better. 1011 10122021-04-10 Jason Merrill <jason@redhat.com> 1013 1014 PR c++/100006 1015 * pt.c (find_parameter_packs_r) [TAG_DEFN]: Look into bases. 1016 10172021-04-09 Patrick Palka <ppalka@redhat.com> 1018 1019 * cp-tree.h (LAMBDA_EXPR_REGENERATED_FROM) 1020 (LAMBDA_EXPR_REGENERATING_TARGS): Replace these with ... 1021 (LAMBDA_EXPR_REGEN_INFO): ... this. 1022 (tree_lambda_expr::regenerated_from) 1023 (tree_lambda_expr::regenerating_targs): Replace these with ... 1024 (tree_lambda_expr::regen_info): ... this. 1025 * constraint.cc (satisfy_declaration_constraints): Adjust 1026 accordingly. 1027 * lambda.c (build_lambda_expr): Likewise. 1028 * pt.c (regenerated_lambda_fn_p): Likewise. 1029 (most_general_lambda): Likewise. 1030 (tsubst_lambda_expr): Likewise. 1031 10322021-04-09 Marek Polacek <polacek@redhat.com> 1033 1034 PR c++/99806 1035 * parser.c (cp_parser_member_declaration): Call 1036 cp_parser_save_default_args even for function templates. Use 1037 STRIP_TEMPLATE on the declaration we're passing. 1038 10392021-04-08 Patrick Palka <ppalka@redhat.com> 1040 1041 PR c++/99874 1042 * constraint.cc (get_normalized_constraints_from_decl): Handle 1043 regenerated lambdas. 1044 (satisfy_declaration_constraints): Likewise. Check for 1045 dependent args later. 1046 * cp-tree.h (LAMBDA_EXPR_INSTANTIATED): Replace with ... 1047 (LAMBDA_EXPR_REGENERATED_FROM): ... this. 1048 (LAMBDA_EXPR_REGENERATING_TARGS): New. 1049 (tree_lambda_expr::regenerated_from): New data member. 1050 (tree_lambda_expr::regenerating_targs): New data member. 1051 (add_to_template_args): Declare. 1052 (regenerated_lambda_fn_p): Likewise. 1053 (most_general_lambda): Likewise. 1054 * lambda.c (build_lambda_expr): Set LAMBDA_EXPR_REGENERATED_FROM 1055 and LAMBDA_EXPR_REGENERATING_TARGS. 1056 * pt.c (add_to_template_args): No longer static. 1057 (tsubst_function_decl): Unconditionally propagate constraints on 1058 the substituted function decl. 1059 (instantiated_lambda_fn_p): Rename to ... 1060 (regenerated_lambda_fn_p): ... this. Check 1061 LAMBDA_EXPR_REGENERATED_FROM instead of 1062 LAMBDA_EXPR_INSTANTIATED. 1063 (most_general_lambda): Define. 1064 (enclosing_instantiation_of): Adjust after renaming 1065 instantiated_lambda_fn_p. 1066 (tsubst_lambda_expr): Don't set LAMBDA_EXPR_INSTANTIATED. Set 1067 LAMBDA_EXPR_REGENERATED_FROM and LAMBDA_EXPR_REGENERATING_TARGS. 1068 Don't substitute or set constraints on the regenerated lambda. 1069 10702021-04-08 Patrick Palka <ppalka@redhat.com> 1071 1072 PR c++/97679 1073 * pt.c (build_deduction_guide): Document OUTER_ARGS. Substitute 1074 them into the propagated constraints. 1075 10762021-04-08 Jason Merrill <jason@redhat.com> 1077 1078 PR c++/91849 1079 * call.c (convert_like_internal): Improve reference diagnostic. 1080 10812021-04-08 Jakub Jelinek <jakub@redhat.com> 1082 1083 PR c++/99859 1084 * constexpr.c (addr_of_non_const_var): New function. 1085 (cxx_bind_parameters_in_call): Set *non_constant_args to true 1086 even if cp_walk_tree on arg with addr_of_non_const_var callback 1087 returns true. 1088 10892021-04-08 Jason Merrill <jason@redhat.com> 1090 1091 PR c++/94529 1092 * pt.c (determine_specialization): Improve diagnostic. 1093 10942021-04-08 Marek Polacek <polacek@redhat.com> 1095 1096 PR c++/99844 1097 * decl.c (build_explicit_specifier): Call 1098 check_for_bare_parameter_packs. 1099 * except.c (build_noexcept_spec): Likewise. 1100 11012021-04-07 Jason Merrill <jason@redhat.com> 1102 1103 PR c++/41723 1104 * parser.c (cp_parser_class_name): Check dependent_scope_p. 1105 11062021-04-07 Jason Merrill <jason@redhat.com> 1107 1108 PR c++/52625 1109 * pt.c (maybe_process_partial_specialization): Check 1110 DECL_SELF_REFERENCE_P. 1111 11122021-04-07 Jason Merrill <jason@redhat.com> 1113 1114 PR c++/92918 1115 * name-lookup.c (push_class_level_binding_1): Do overload a new 1116 function with a previous using-declaration. 1117 11182021-04-06 Jason Merrill <jason@redhat.com> 1119 1120 PR c++/96673 1121 * init.c (get_nsdmi): Don't defer access checking. 1122 11232021-04-06 Jason Merrill <jason@redhat.com> 1124 1125 PR c++/99901 1126 * decl.c (cp_finish_decl): mark_needed an implicitly inline 1127 static data member with an out-of-class redeclaration. 1128 11292021-04-06 Jason Merrill <jason@redhat.com> 1130 1131 PR c++/91241 1132 * mangle.c (write_compact_number): Add sanity check. 1133 (write_local_name): Use list_length for parm number. 1134 11352021-04-06 Patrick Palka <ppalka@redhat.com> 1136 1137 PR c++/99899 1138 * pt.c (do_auto_deduction): Don't exit early when deducing the 1139 array type of a structured binding. Also handle adc_decomp_type 1140 during constraint checking. 1141 11422021-04-05 Jason Merrill <jason@redhat.com> 1143 1144 PR c++/96311 1145 * typeck.c (check_return_expr): Call mark_exp_read in dependent 1146 case. 1147 11482021-04-05 Jason Merrill <jason@redhat.com> 1149 1150 PR c++/98440 1151 * typeck.c (build_reinterpret_cast_1): Don't perform 1152 temporary materialization. 1153 11542021-04-05 Jason Merrill <jason@redhat.com> 1155 1156 PR c++/95317 1157 * pt.c (lookup_template_class_1): Do tsubst_enum when 1158 tsubsting a generic lambda. 1159 11602021-04-05 Jason Merrill <jason@redhat.com> 1161 1162 PR c++/95870 1163 * pt.c (enclosing_instantiation_of): Compare DECL_SOURCE_LOCATION if 1164 there is no enclosing non-lambda function. 1165 11662021-04-05 Nathan Sidwell <nathan@acm.org> 1167 1168 PR c++/99380 1169 * module.cc (name_pending_imports): Drop 'atend' parm. Don't 1170 query export when not needed. 1171 (preprocess_module, preprocessed_module): Adjust. 1172 11732021-04-05 Jason Merrill <jason@redhat.com> 1174 1175 PR c++/99066 1176 * pt.c (mark_decl_instantiated): Set DECL_EXTERNAL. 1177 11782021-04-05 Jason Merrill <jason@redhat.com> 1179 1180 PR c++/99201 1181 * pt.c (class el_data): Add visited field. 1182 (extract_local_specs): Pass it to cp_walk_tree. 1183 (extract_locals_r): Walk into the body of a lambda. 1184 11852021-04-05 Jason Merrill <jason@redhat.com> 1186 1187 * ptree.c (cxx_print_decl): Check DECL_MODULE_IMPORT_P on 1188 template result. 1189 11902021-04-04 Jason Merrill <jason@redhat.com> 1191 1192 PR c++/99643 1193 * typeck2.c (massage_init_elt): Don't strip TARGET_EXPR. 1194 11952021-04-03 Marek Polacek <polacek@redhat.com> 1196 1197 PR c++/91416 1198 * parser.c: Create a GC root for attributes in a decl specifier. 1199 (cp_parser_type_specifier): Push/pop ->attributes onto/from it. 1200 12012021-04-03 Jason Merrill <jason@redhat.com> 1202 1203 PR c++/91217 1204 * pt.c (tsubst_lambda_expr): Skip the body block from 1205 DECL_SAVED_TREE. 1206 12072021-04-03 Jason Merrill <jason@redhat.com> 1208 1209 PR c++/90664 1210 * cvt.c (can_convert_qual): Check fnptr_conv_p. 1211 12122021-04-03 Jason Merrill <jason@redhat.com> 1213 1214 PR c++/97900 1215 * pt.c (regenerate_decl_from_template): tsubst_decl 1216 the parms. 1217 12182021-04-02 Patrick Palka <ppalka@redhat.com> 1219 1220 PR c++/99869 1221 * parser.c (do_range_for_auto_deduction): Pass adc_variable_type 1222 to do_auto_deduction. 1223 12242021-04-02 Patrick Palka <ppalka@redhat.com> 1225 1226 PR c++/99586 1227 * semantics.c (finish_compound_literal): Check 1228 template_placeholder_p instead of type_uses_auto. 1229 12302021-04-02 Jason Merrill <jason@redhat.com> 1231 1232 PR c++/97938 1233 * cp-tree.h (PACK_EXPANSION_AUTO_P): New. 1234 * lambda.c (add_capture): Set it. 1235 * pt.c (tsubst_pack_expansion): Handle it. 1236 12372021-04-02 Nathan Sidwell <nathan@acm.org> 1238 1239 * cp-tree.h (lang_decl_base): Correct module flag comment. 1240 * module.cc (trees_in::assert_definition): Break out 1241 not_tmpl var. 1242 (trees_out::lang_decl_bools): Do not write purview for header units. 1243 12442021-04-01 Marek Polacek <polacek@redhat.com> 1245 1246 PR c++/99831 1247 * method.c (defaulted_late_check): ++ and -- function_depth around 1248 the call to synthesize_method. 1249 * pt.c: Remove the saved_trees global. 1250 12512021-04-01 Jason Merrill <jason@redhat.com> 1252 1253 PR c++/99583 1254 PR c++/99584 1255 * tree.c (cp_walk_subtrees) [FUNCTION_TYPE]: Walk into 1256 TYPE_RAISES_EXCEPTIONS. 1257 12582021-04-01 Iain Sandoe <iain@sandoe.co.uk> 1259 1260 * mapper-client.cc (INCLUDE_MAP): New; require map to be 1261 included from system.h. 1262 * mapper-resolver.cc (INCLUDE_MAP): Likewise. 1263 12642021-04-01 Jason Merrill <jason@redhat.com> 1265 1266 PR c++/98481 1267 * mangle.c (write_expression): Adjust. 1268 * class.c (find_abi_tags_r): Disable PR98481 fix for ABI v14. 1269 (mark_abi_tags_r): Likewise. 1270 12712021-04-01 Nathan Sidwell <nathan@acm.org> 1272 1273 PR c++/99283 1274 * module.cc (trees_out::decl_node): Adjust importedness reference 1275 assert. 1276 (module_state::intercluster_seed): New. Seed both imports and 1277 inter-cluster references. Broken out of ... 1278 (module_state::write_cluster): ... here. Call it. 1279 12802021-03-31 Jason Merrill <jason@redhat.com> 1281 1282 PR c++/99445 1283 * tree.c (strip_typedefs): Handle TYPE_PACK_EXPANSION. 1284 12852021-03-31 Patrick Palka <ppalka@redhat.com> 1286 1287 PR c++/88115 1288 * mangle.c (write_expression): Adjust the mangling of 1289 __alignof__. 1290 12912021-03-31 Patrick Palka <ppalka@redhat.com> 1292 1293 PR c++/99815 1294 * pt.c (placeholder_type_constraint_dependent_p): Expand 1295 argument packs to separate the first non-pack argument 1296 from the rest. 1297 12982021-03-30 Nathan Sidwell <nathan@acm.org> 1299 1300 PR c++/99283 1301 * module.cc (dumper::operator): Make less brittle. 1302 (trees_out::core_bools): VAR_DECLs always have a context. 1303 (trees_out::key_mergeable): Use same_type_p for asserting. 1304 (trees_in::read_var_def): Propagate 1305 DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P. 1306 13072021-03-30 Jakub Jelinek <jakub@redhat.com> 1308 1309 PR c++/99790 1310 * cp-gimplify.c (cp_gimplify_expr): Handle PTRMEM_CST. 1311 13122021-03-26 Marek Polacek <polacek@redhat.com> 1313 1314 PR c++/98352 1315 * method.c (implicitly_declare_fn): Pass &raises to 1316 synthesized_method_walk. 1317 13182021-03-26 Nathan Sidwell <nathan@acm.org> 1319 1320 PR c++/99283 1321 * cp-tree.h (DECL_MODULE_CHECK): Ban TEMPLATE_DECL. 1322 (SET_TYPE_TEMPLATE_INFO): Restore Alias template setting. 1323 * decl.c (duplicate_decls): Remove template_decl module flag 1324 propagation. 1325 * module.cc (merge_kind_name): Add alias tmpl spec as a thing. 1326 (dumper::impl::nested_name): Adjust for template-decl module flag 1327 change. 1328 (trees_in::assert_definition): Likewise. 1329 (trees_in::install_entity): Likewise. 1330 (trees_out::decl_value): Likewise. Remove alias template 1331 separation of template and type_decl. 1332 (trees_in::decl_value): Likewise. 1333 (trees_out::key_mergeable): Likewise, 1334 (trees_in::key_mergeable): Likewise. 1335 (trees_out::decl_node): Adjust for template-decl module flag 1336 change. 1337 (depset::hash::make_dependency): Likewise. 1338 (get_originating_module, module_may_redeclare): Likewise. 1339 (set_instantiating_module, set_defining_module): Likewise. 1340 * name-lookup.c (name_lookup::search_adl): Likewise. 1341 (do_pushdecl): Likewise. 1342 * pt.c (build_template_decl): Likewise. 1343 (lookup_template_class_1): Remove special alias_template handling 1344 of DECL_TI_TEMPLATE. 1345 (tsubst_template_decl): Likewise. 1346 13472021-03-26 Jakub Jelinek <jakub@redhat.com> 1348 1349 PR c++/99705 1350 * tree.c (bot_manip): Remap artificial automatic temporaries mentioned 1351 in DECL_EXPR or in BIND_EXPR_VARS. 1352 13532021-03-25 Jakub Jelinek <jakub@redhat.com> 1354 1355 PR c++/99672 1356 * parser.c (cp_parser_postfix_expression): For calls, create 1357 combined_loc and temporarily set input_location to it before 1358 calling finish_call_expr. 1359 13602021-03-25 Marek Polacek <polacek@redhat.com> 1361 1362 PR c++/94751 1363 * call.c (build_over_call): Maybe call mark_used in case 1364 deduce_inheriting_ctor fails and return error_mark_node. 1365 * cp-tree.h (deduce_inheriting_ctor): Adjust declaration. 1366 * method.c (deduce_inheriting_ctor): Return bool if the deduction 1367 fails. 1368 (implicitly_declare_fn): If raises is error_mark_node, call 1369 synthesized_method_walk with diag being true. 1370 13712021-03-25 Jakub Jelinek <jakub@redhat.com> 1372 1373 PR c++/99745 1374 * decl2.c (grokbitfield): Diagnose bitfields containing bare parameter 1375 packs and don't set DECL_BIT_FIELD_REPRESENTATIVE in that case. 1376 13772021-03-25 Marek Polacek <polacek@redhat.com> 1378 1379 PR c++/99331 1380 * call.c (build_converted_constant_expr_internal): Don't emit 1381 -Wconversion warnings. 1382 13832021-03-25 Jakub Jelinek <jakub@redhat.com> 1384 1385 PR c++/99565 1386 * call.c (build_conditional_expr_1): Pass OEP_ADDRESS_OF_SAME_FIELD 1387 to operand_equal_p. 1388 * cvt.c (convert_to_void): Preserve location_t on COND_EXPR or 1389 or COMPOUND_EXPR. 1390 13912021-03-23 Nathan Sidwell <nathan@acm.org> 1392 1393 PR c++/99283 1394 * name-lookup.c (check_module_override): Set global or partition 1395 DUP on the binding vector. 1396 13972021-03-23 Marek Polacek <polacek@redhat.com> 1398 1399 PR c++/99318 1400 * decl2.c (cp_warn_deprecated_use_scopes): Only call 1401 cp_warn_deprecated_use when decl is a namespace, class, or enum. 1402 14032021-03-23 Nathan Sidwell <nathan@acm.org> 1404 1405 PR c++/99239 1406 * decl.c (duplicate_decls): Remove assert about maybe-imported 1407 artificial decls. 1408 14092021-03-23 Jakub Jelinek <jakub@redhat.com> 1410 1411 PR c++/99650 1412 * decl.c (cp_finish_decomp): Diagnose void initializers when 1413 using tuple_element and get. 1414 14152021-03-22 Nathan Sidwell <nathan@acm.org> 1416 1417 PR c++/99480 1418 * module.cc (depset::hash::make_dependency): Propagate flags for 1419 partial specialization. 1420 (module_may_redeclare): Handle partial specialization. 1421 14222021-03-22 Nathan Sidwell <nathan@acm.org> 1423 1424 PR c++/99425 1425 * cp-tree.h (map_context_from, map_context_to): Delete. 1426 (add_mergeable_specialization): Add is_alias parm. 1427 * pt.c (add_mergeable_specialization): Add is_alias parm, add them. 1428 * module.cc (map_context_from, map_context_to): Delete. 1429 (trees_in::decl_value): Add specializations later, adjust call. 1430 Drop useless alias lookup. Set duplicate fn parm context. 1431 (check_mergeable_decl): Drop context mapping. 1432 (trees_in::is_matching_decl): Likewise. 1433 (trees_in::read_function_def): Drop parameter context adjustment 1434 here. 1435 14362021-03-22 Martin Liska <mliska@suse.cz> 1437 1438 PR c++/99687 1439 * module.cc (fini_modules): Call vec_free instead of delete. 1440 14412021-03-20 Jakub Jelinek <jakub@redhat.com> 1442 1443 PR debug/99230 1444 * cp-gimplify.c (cp_genericize_r) <case STATEMENT_LIST>: Remove 1445 special code, instead call c_genericize_control_stmt. 1446 14472021-03-19 Jakub Jelinek <jakub@redhat.com> 1448 1449 PR c++/99456 1450 * constexpr.c (cxx_eval_constant_expression): For CONVERT_EXPR from 1451 INDIRECT_TYPE_P to ARITHMETIC_TYPE_P, when !ctx->manifestly_const_eval 1452 don't diagnose it, set *non_constant_p nor return t. 1453 14542021-03-19 Marek Polacek <polacek@redhat.com> 1455 1456 PR c++/99500 1457 * parser.c (cp_parser_requirement_parameter_list): Handle 1458 error_mark_node. 1459 14602021-03-18 Marek Polacek <polacek@redhat.com> 1461 1462 * pt.c (tsubst_copy_and_build) <case FLOAT_EXPR>: Remove. 1463 14642021-03-18 Marek Polacek <polacek@redhat.com> 1465 1466 * pt.c (tsubst_copy_and_build): Add assert. 1467 14682021-03-18 Iain Sandoe <iain@sandoe.co.uk> 1469 1470 PR objc++/49070 1471 * parser.c (cp_debug_parser): Add Objective-C++ message 1472 state flag. 1473 (cp_parser_nested_name_specifier_opt): Allow colon to 1474 terminate an assignment-expression when parsing Objective- 1475 C++ messages. 1476 (cp_parser_objc_message_expression): Set and clear message 1477 parsing state on entry and exit. 1478 * parser.h (struct cp_parser): Add a context flag for 1479 Objective-C++ message state. 1480 14812021-03-18 Martin Liska <mliska@suse.cz> 1482 1483 PR c++/99617 1484 * coroutines.cc (struct var_nest_node): Init then_cl and else_cl 1485 to NULL. 1486 14872021-03-17 Marek Polacek <polacek@redhat.com> 1488 1489 PR c++/97973 1490 * call.c (conv_unsafe_in_template_p): New. 1491 (convert_like): Use it. 1492 14932021-03-17 Anthony Sharp <anthonysharp15@gmail.com> 1494 Jason Merrill <jason@redhat.com> 1495 1496 * semantics.c (get_class_access_diagnostic_decl): New 1497 function that examines special cases when a parent 1498 class causes a private access failure. 1499 (enforce_access): Slightly modified to call function 1500 above. 1501 15022021-03-16 Jason Merrill <jason@redhat.com> 1503 1504 * tree.c (cp_tree_equal): Use real_identical. 1505 15062021-03-16 Jakub Jelinek <jakub@redhat.com> 1507 1508 PR c++/99613 1509 * decl.c (expand_static_init): For thread guards, call __cxa_atexit 1510 before calling __cxa_guard_release rather than after it. Formatting 1511 fixes. 1512 15132021-03-16 Martin Liska <mliska@suse.cz> 1514 Jason Merrill <jason@redhat.com> 1515 1516 PR c++/99108 1517 * call.c (get_function_version_dispatcher): Handle 1518 DECL_LOCAL_DECL_P. 1519 * decl.c (maybe_version_functions): Likewise. 1520 (maybe_mark_function_versioned): New. 1521 * name-lookup.c (push_local_extern_decl_alias): No longer static. 1522 * name-lookup.h (push_local_extern_decl_alias): Adjust. 1523 15242021-03-16 Nathan Sidwell <nathan@acm.org> 1525 1526 PR c++/99496 1527 * module.cc (trees_out::decl_value): Adjust typedef streaming, 1528 indicate whether it is a dependent alias. 1529 (trees_in::decl_value): Likewise. Set as dependent alias, if it 1530 is one. 1531 15322021-03-15 Iain Sandoe <iain@sandoe.co.uk> 1533 1534 PR c++/99047 1535 * coroutines.cc (expand_one_await_expression): If the 1536 await_ready() expression is not a boolean then convert it 1537 as required. 1538 15392021-03-15 Iain Sandoe <iain@sandoe.co.uk> 1540 1541 PR c++/98704 1542 * coroutines.cc (build_actor_fn): Make destroy index 1 1543 correspond to the abnormal unhandled_exception() exit. 1544 Substitute the proxy for the resume index. 1545 (coro_rewrite_function_body): Arrange to reset the resume 1546 index and make done = true for a rethrown exception from 1547 unhandled_exception (). 1548 (morph_fn_to_coro): Adjust calls to build_actor_fn and 1549 coro_rewrite_function_body. 1550 15512021-03-15 Iain Sandoe <iain@sandoe.co.uk> 1552 1553 PR c++/98480 1554 * coroutines.cc (replace_continue): Rewrite continue into 1555 'goto label'. 1556 (await_statement_walker): Handle await expressions in the 1557 initializer, condition and iteration expressions of for 1558 loops. 1559 15602021-03-15 Iain Sandoe <iain@sandoe.co.uk> 1561 1562 PR c++/96749 1563 * coroutines.cc (flatten_await_stmt): Allow for the case 1564 where a target expression variable only has uses in the 1565 second part of a compound expression. 1566 (maybe_promote_temps): Avoid emiting empty statements. 1567 15682021-03-15 Tobias Burnus <tobias@codesourcery.com> 1569 1570 PR c++/99509 1571 * decl.c (cp_finish_decl): For 'omp declare target implicit' vars, 1572 ensure that the varpool node is marked as offloadable. 1573 15742021-03-12 Nathan Sidwell <nathan@acm.org> 1575 1576 PR c++/99238 1577 * module.cc (depset::hash::add_binding_entity): Assert not 1578 visited. 1579 (depset::add::add_specializations): Likewise. 1580 * name-lookup.c (name_lookup::dedup): New. 1581 (name_lookup::~name_lookup): Assert not deduping. 1582 (name_lookup::restore_state): Likewise. 1583 (name_lookup::add_overload): Replace outlined code with dedup 1584 call. 1585 (name_lookup::add_value): Likewise. 1586 (name_lookup::search_namespace_only): Likewise. 1587 (name_lookup::adl_namespace_fns): Likewise. 1588 (name_lookup::adl_class_fns): Likewise. 1589 (name_lookup::search_adl): Likewise. Add clearing dedup call. 1590 (name_lookup::search_qualified): Likewise. 1591 (name_lookup::search_unqualified): Likewise. 1592 15932021-03-12 Jakub Jelinek <jakub@redhat.com> 1594 1595 PR c++/99507 1596 * call.c (build_over_call): For immediate evaluation of functions 1597 that return references, undo convert_from_reference effects before 1598 calling cxx_constant_value and call convert_from_reference 1599 afterwards. 1600 16012021-03-11 Nathan Sidwell <nathan@acm.org> 1602 1603 PR c++/99248 1604 * name-lookup.c (lookup_elaborated_type_1): Access slot not bind 1605 when there's a binding vector. 1606 * ptree.c (cxx_print_xnode): Lazy flags are no longer a thing. 1607 16082021-03-11 Nathan Sidwell <nathan@acm.org> 1609 1610 PR c++/99528 1611 * module.cc (enum merge_kind): Delete MK_type_tmpl_spec, 1612 MK_decl_tmpl_spec. 1613 (trees_in::decl_value): Adjust add_mergeable_specialization call. 1614 (trees_out::get_merge_kind): Adjust detecting a partial template 1615 instantiation. 1616 (trees_out::key_mergeable): Adjust handling same. 1617 (trees_in::key_mergeabvle): Likewise. 1618 16192021-03-10 Nathan Sidwell <nathan@acm.org> 1620 1621 PR c++/99423 1622 * module.cc (post_load_processing): Assert not gcable. 1623 (laxy_load_pendings): Extend no-gc region around 1624 post_load_processing. 1625 16262021-03-10 Nathan Sidwell <nathan@acm.org> 1627 1628 PR c++/99508 1629 * decl.c (make_rtl_for_nonlocal_decl): Propagate local-extern's 1630 assembler name to the ns alias. 1631 16322021-03-09 Jakub Jelinek <jakub@redhat.com> 1633 1634 PR c++/99459 1635 * coroutines.cc (build_co_await): Look through NOP_EXPRs in 1636 build_special_member_call return value to find the CALL_EXPR. 1637 Simplify. 1638 16392021-03-09 Nathan Sidwell <nathan@acm.org> 1640 1641 PR c++/99472 1642 * parser.c (cp_parser_diagnose_invalid_type_name): Clarify 1643 that C++20 does not yet imply modules. 1644 16452021-03-08 Nathan Sidwell <nathan@acm.org> 1646 1647 PR c++/99436 1648 * name-lookup.c (get_cxx_dialect_name): Add cxx23. 1649 16502021-03-08 Nathan Sidwell <nathan@acm.org> 1651 1652 * lex.c (module_token_filter::resume): Ignore module-decls inside 1653 header-unit. 1654 * parser.c (cp_parser_module_declaration): Reject in header-unit. 1655 16562021-03-08 Nathan Sidwell <nathan@acm.org> 1657 1658 PR c++/99285 1659 * cp-tree.h (match_mergeable_specialization) 1660 (add_mergeable_specialization): Adjust parms. 1661 * module.cc (trees_in::decl_value): Adjust 1662 add_mergeable_specialization calls. 1663 (trees_out::key_mergeable): Adjust match_mergeable_specialization 1664 calls. 1665 (specialization_add): Likewise. 1666 * pt.c (match_mergeable_specialization): Do not insert. 1667 (add_mergeable_specialization): Add to hash table here. 1668 16692021-03-06 Patrick Palka <ppalka@redhat.com> 1670 Jakub Jelinek <jakub@redhat.com> 1671 1672 PR c++/99287 1673 * constexpr.c (cxx_eval_increment_expression): Pass lval when 1674 evaluating the MODIFY_EXPR, and update 'mod' with the result of 1675 this evaluation. Check *non_constant_p afterwards. For prefix 1676 ops, just return 'mod'. 1677 16782021-03-06 Patrick Palka <ppalka@redhat.com> 1679 Jakub Jelinek <jakub@redhat.com> 1680 1681 PR c++/96330 1682 * pt.c (tsubst_copy) <case TEMPLATE_ID_EXPR>: Rename local 1683 variable 'fn' to 'tmpl'. Handle a variable template-id by 1684 calling lookup_template_variable. 1685 16862021-03-06 Patrick Palka <ppalka@redhat.com> 1687 1688 PR c++/99365 1689 * pt.c (unify) <case TEMPLATE_TYPE_PARM>: Pass targs as 1690 outer_targs to do_auto_deduction. 1691 (placeholder_type_constraint_dependent_p): Define. 1692 (do_auto_deduction): When processing_template_decl != 0 1693 and context is adc_unify and we have constraints, pretend the 1694 constraints are satisfied instead of punting. Otherwise don't 1695 punt unless placeholder_type_constraint_dependent_p holds. 1696 Add some clarifying sanity checks. Add a hack to add missing 1697 outermost template levels to outer_args before checking 1698 satisfaction. Don't substitute outer_targs into type if it's 1699 already been done. 1700 17012021-03-05 Marek Polacek <polacek@redhat.com> 1702 1703 PR c++/99374 1704 * call.c (standard_conversion): When converting pointers to 1705 member, don't return NULL when the bases are equivalent but 1706 incomplete. 1707 17082021-03-05 Marek Polacek <polacek@redhat.com> 1709 1710 PR c++/99120 1711 * name-lookup.c (check_local_shadow): Check if the type of decl 1712 is non-null before checking TYPE_PTR*. 1713 17142021-03-05 Nathan Sidwell <nathan@acm.org> 1715 1716 PR c++/99245 1717 * module.cc (module_state::write_cluster): Relax binding assert. 1718 17192021-03-05 Nathan Sidwell <nathan@acm.org> 1720 1721 PR c++/99377 1722 * pt.c (instantiate_decl): Call set_instantiating_module. 1723 17242021-03-05 Iain Sandoe <iain@sandoe.co.uk> 1725 1726 PR c++/98118 1727 * coroutines.cc (build_co_await): Use type_build_ctor_call() 1728 to determine cases when a CTOR needs to be built. 1729 (flatten_await_stmt): Likewise. 1730 (morph_fn_to_coro): Likewise. 1731 17322021-03-05 Iain Sandoe <iain@sandoe.co.uk> 1733 1734 PR c++/95616 1735 * coroutines.cc (coro_diagnose_throwing_fn): New helper. 1736 (coro_diagnose_throwing_final_aw_expr): New helper. 1737 (build_co_await): Diagnose throwing final await expression 1738 components. 1739 (build_init_or_final_await): Diagnose a throwing promise 1740 final_suspend() call. 1741 17422021-03-05 Iain Sandoe <iain@sandoe.co.uk> 1743 1744 PR c++/95615 1745 * coroutines.cc (struct param_info): Track parameter copies that need 1746 a DTOR. 1747 (coro_get_frame_dtor): New helper function factored from build_actor(). 1748 (build_actor_fn): Use coro_get_frame_dtor(). 1749 (morph_fn_to_coro): Track parameters that need DTORs on exception, 1750 likewise the frame promise and the return object. On exception, run the 1751 DTORs for these, destroy the frame and then rethrow the exception. 1752 17532021-03-05 Nathan Sidwell <nathan@acm.org> 1754 1755 PR c++/99389 1756 * pt.c (instantiate_class_template_1): Set instantiating module 1757 here. 1758 17592021-03-05 Tobias Burnus <tobias@codesourcery.com> 1760 1761 PR c/99137 1762 * parser.c (cp_parser_oacc_clause_async): Reject comma expressions. 1763 17642021-03-04 Jakub Jelinek <jakub@redhat.com> 1765 1766 PR c++/88146 1767 PR c++/99362 1768 * cvt.c (convert_to_void): Revert 2019-10-17 changes. Clarify 1769 comment. 1770 17712021-03-04 Nathan Sidwell <nathan@acm.org> 1772 1773 PR c++/99170 1774 * module.cc (class uintset): Delete. 1775 (typedef attached_map_t): A hash map. 1776 (attached_table): Use attached_map_t. Adjust uses ... 1777 (trees_out::decl_value, trees_in::decl_value): ... here ... 1778 (trees_out::key_mergeable): ... here ... 1779 (trees_in::key_mergeable): ... here ... 1780 (maybe_attach_decl): ... here ... 1781 (direct_import): ... and here. 1782 17832021-03-04 Nathan Sidwell <nathan@acm.org> 1784 1785 PR c++/99170 1786 * cp-tree.h 1787 * lex.c (cxx_dup_lang_specific_decl): Adjust for module_attached_p 1788 rename. 1789 * module.cc (class pending_key): New. 1790 (default_hash_traits<pending_key>): New specialization. 1791 (pending_map_t): New typedef. 1792 (pending_table): Replace old table. 1793 (trees_out::lang_decl_bools): Adjust. 1794 (trees_in::lang_decl_bools): Adjust. 1795 (trees_in::install_entity): Drop pending member and specialization 1796 handling. 1797 (find_pending_key): New. 1798 (depset::hash::fiund_dependencies): Use it. 1799 (pendset_lazy_load): Delete. 1800 (module_state::write_cluster): Don't count pendings here. Bye 1801 Duff's device-like thing. 1802 (module_state::write_pendings): Reimplement. 1803 (module_state::read_pendings): Reimplement. 1804 (lazy_specializations_p): Delete. 1805 (module_state::write): Adjust write_pendings call. 1806 (lazy_load_pendings): New. 1807 (lazy_load_specializations): Delete. 1808 (lazy_load_members): Delete. 1809 (init_modules): Adjust. 1810 * name-lookup.c (maybe_lazily_declare): Call lazy_load_pendings 1811 not lazy_load_members. 1812 (note_pending_specializations): Delete. 1813 (load_pending_specializations): Delete. 1814 * name-lookup.h (BINDING_VECTR_PENDING_SPECIALIZATIONS_P): Delete. 1815 (BINDING_VECTOR_PENDING_MEMBERS_P): Delete. 1816 (BINDING_VECTR_PENDING_MEMBERS_P): Delete. 1817 (note_pending_specializations): Delete. 1818 (load_pending_specializations): Delete. 1819 * pt.c (lookup_template_class_1): Call lazy_load_pendings not 1820 lazy_load_specializations. 1821 (instantiate_template_class_1): Likewise. 1822 (instantiate_decl): Call lazy_load_pendings. 1823 * typeck.c (complete_type): Likewise. 1824 18252021-03-03 Nathan Sidwell <nathan@acm.org> 1826 1827 PR c++/99170 1828 * module.cc (post_load_decls): New. 1829 (lazy_snum, recursive_lazy): Move earlier. 1830 (module_state::read_cluster): Push cloning onto post_load_decls. 1831 (post_load_processing): New. Do the cloning here. 1832 (module_state::read_inits): Call post_load_processing. 1833 (module_state::read_language): Likewise. 1834 (lazy_load_binding, lazy_load_specializations): Likewise 1835 (lazy_load_members): Likewise 1836 18372021-03-03 Nathan Sidwell <nathan@acm.org> 1838 1839 PR c++/99170 1840 * module.cc (trees_out::decl_value): Stream specialization keys 1841 after decl. 1842 (trees_in::decl_value): Stream them back and insert after 1843 completing the decl. 1844 (trees_out::key_mergeable): Drop some streaming here ... 1845 (trees_in::key_mergeable): ... and here. Don't insert into 1846 specialization tables. 1847 18482021-03-03 Patrick Palka <ppalka@redhat.com> 1849 1850 * constraint.cc (struct sat_info): Document the different 1851 meanings of noisy() and diagnose_unsatisfaction_p() during 1852 satisfaction and requires-expression evaluation. 1853 (tsubst_valid_expression_requirement): Take a sat_info instead 1854 of a subst_info. Perform the substitution quietly first. Fold 1855 in error-replaying code from diagnose_valid_expression. 1856 (tsubst_simple_requirement): Take a sat_info instead of a 1857 subst_info. 1858 (tsubst_type_requirement_1): New. Fold in error-replaying code 1859 from diagnose_valid_type. 1860 (tsubst_type_requirement): Use the above. Take a sat_info 1861 instead of a subst_info. 1862 (tsubst_compound_requirement): Likewise. Fold in 1863 error-replaying code from diagnose_compound_requirement. 1864 (tsubst_nested_requirement): Take a sat_info instead of a 1865 subst_info. Fold in error-replaying code from 1866 diagnose_nested_requirement. 1867 (tsubst_requirement): Take a sat_info instead of a subst_info. 1868 (tsubst_requires_expr): Split into two versions, one that takes 1869 a sat_info argument and another that takes a complain and 1870 in_decl argument. Remove outdated documentation. Document the 1871 effects of the sat_info argument. Don't short-circuit 1872 processing of requirements when diagnosing unsatisfaction, 1873 mirroring diagnose_requires_expr. 1874 (satisfy_nondeclaration_constraint) <case REQUIRES_EXPR>: Remove 1875 assert, and se the three-parameter version of tsubst_requires_expr. 1876 (diagnose_trait_expr): Make static. Take a template argument 1877 vector instead of a parameter mapping. 1878 (diagnose_valid_expression): Remove. 1879 (diagnose_valid_type): Remove. 1880 (diagnose_simple_requirement): Remove. 1881 (diagnose_compound_requirement): Remove. 1882 (diagnose_type_requirement): Remove. 1883 (diagnose_nested_requirement): Remove. 1884 (diagnose_requirement): Remove. 1885 (diagnose_requires_expr): Remove. 1886 (diagnose_atomic_constraint): Take a sat_info instead of a 1887 subst_info. Adjust call to diagnose_trait_expr. Call 1888 tsubst_requires_expr instead of diagnose_requires_expr. 1889 (diagnose_constraints): Remove special casing of REQUIRES_EXPR 1890 and just always call constraint_satisfaction_value. 1891 18922021-03-03 Patrick Palka <ppalka@redhat.com> 1893 1894 * constexpr.c (cxx_eval_call_expression): Adjust call to 1895 evaluate_concept_check. 1896 (cxx_eval_constant_expression) <case REQUIRES_EXPR>: Use 1897 evaluate_requires_expression instead of 1898 satisfy_constraint_expression. 1899 <case TEMPLATE_ID_EXPR>: Adjust call to evaluate_concept_check. 1900 * constraint.cc (struct sat_info): Adjust comment about which 1901 satisfaction entrypoints use noisy-unsat. 1902 (normalize_template_requirements): Remove (and adjust callers 1903 appropriately). 1904 (normalize_nontemplate_requirements): Likewise. 1905 (tsubst_nested_requirement): Use constraint_satisfaction_value 1906 instead of satisfy_constraint_expression, which'll do the 1907 noisy replaying of ill-formed quiet satisfaction for us. 1908 (decl_satisfied_cache): Adjust comment. 1909 (satisfy_constraint): Rename to ... 1910 (satisfy_normalized_constraints): ... this. 1911 (satisfy_associated_constraints): Remove (and make its 1912 callers check for dependent arguments). 1913 (satisfy_constraint_expression): Rename to ... 1914 (satisfy_nondeclaration_constraints): ... this. Assert that 1915 'args' is empty when 't' is a concept-id. Removing handling 1916 bare constraint-expressions, and handle REQUIRES_EXPRs 1917 specially. Adjust comment accordingly. 1918 (satisfy_declaration_constraints): Assert in the two-parameter 1919 version that 't' is not a TEMPLATE_DECL. Adjust following 1920 removal of normalize_(non)?template_requirements and 1921 satisfy_asociated_constraints. 1922 (constraint_satisfaction_value): Combine the two- and 1923 three-parameter versions in the natural way. 1924 (constraints_satisfied_p): Combine the one- and two-parameter 1925 versions in the natural way. Improve documentation. 1926 (evaluate_requires_expr): Define. 1927 (evaluate_concept_check): Remove 'complain' parameter. Use 1928 constraint_satisfaction_value instead of 1929 satisfy_constraint_expression. 1930 (diagnose_nested_requirement): Adjust following renaming of 1931 satisfy_constraint_expression. 1932 (diagnose_constraints): Handle REQUIRES_EXPR by going through 1933 diagnose_requires_expr directly instead of treating it as a 1934 constraint-expression. Improve documentation. 1935 * cp-gimplify.c (cp_genericize_r) <case CALL_EXPR>: Adjust call 1936 to evaluate_concept_check. 1937 <case REQUIRES_EXPR>: Use evaluate_requires_expr instead of 1938 constraints_satisfied_p. 1939 <case TEMPLATE_ID_EXPR>: Adjust call to evaluate_concept_check. 1940 * cp-tree.h (evaluate_requires_expr): Declare. 1941 (evaluate_concept_check): Remove tsubst_flag_t parameter. 1942 (satisfy_constraint_expression): Remove declaration. 1943 (constraints_satisfied_p): Remove one-parameter declaration. 1944 Add a default argument to the two-parameter declaration. 1945 * cvt.c (convert_to_void): Adjust call to 1946 evaluate_concept_check. 1947 19482021-03-03 Jakub Jelinek <jakub@redhat.com> 1949 1950 PR c++/82959 1951 * call.c (op_is_ordered): Handle TRUTH_ANDIF_EXPR, TRUTH_ORIF_EXPR 1952 and COMPOUND_EXPR. 1953 19542021-03-03 Marek Polacek <polacek@redhat.com> 1955 1956 PR c++/97034 1957 PR c++/99009 1958 * pt.c (build_deduction_guide): Use INNERMOST_TEMPLATE_ARGS. 1959 (maybe_aggr_guide): Use the original template type where needed. In 1960 a class member template, partially instantiate the result of 1961 collect_ctor_idx_types. 1962 (do_class_deduction): Defer the deduction until the enclosing 1963 scope is non-dependent. 1964 19652021-03-03 Jason Merrill <jason@redhat.com> 1966 1967 PR c++/95675 1968 * call.c (build_temp): Wrap a CALL_EXPR in a TARGET_EXPR 1969 if it didn't get one before. 1970 19712021-03-03 Nathan Sidwell <nathan@acm.org> 1972 1973 PR c++/99344 1974 * module.cc (trees_out::decl_node): Small refactor. 1975 (depset::hash::add_binding_entity): Return true on meeting an 1976 import. Set namespace's import here. 1977 (module_state:write_namespaces): Inform of purview too. 1978 (module_state:read_namespaces): Adjust. 1979 * name-lookup.c (implicitly_export_namespace): Delete. 1980 (do_pushdecl): Don't call it. 1981 (push_namespace): Likewise, set purview. 1982 (add_imported_namespace): Reorder parms. 1983 * name-lookup.h (add_imported_namespace): Alter param ordering. 1984 19852021-03-02 Martin Sebor <msebor@redhat.com> 1986 1987 PR c++/99251 1988 * class.c (build_base_path): Call build_if_nonnull. 1989 * cp-tree.h (build_if_nonnull): Declare. 1990 * rtti.c (ifnonnull): Rename... 1991 (build_if_nonnull): ...to this. Set no-warning bit on COND_EXPR. 1992 (build_dynamic_cast_1): Adjust to name change. 1993 19942021-03-02 Patrick Palka <ppalka@redhat.com> 1995 1996 PR c++/96443 1997 PR c++/96960 1998 * constraint.cc (type_deducible_p): Don't substitute into the 1999 constraints, and instead just pass 'args' to do_auto_deduction 2000 as the outer template arguments. 2001 (tsubst_parameter_mapping): Remove confused code for handling 2002 placeholder type arguments. 2003 (normalize_placeholder_type_constraint): Define. 2004 (satisfy_constraint_expression): Use it to handle placeholder 2005 'auto' types. 2006 * cp-tree.h (PLACEHOLDER_TYPE_CONSTRAINTS_INFO): Define. 2007 (PLACEHOLDER_TYPE_CONSTRAINTS): Redefine in terms of the above. 2008 * pt.c (tsubst) <case TEMPLATE_TYPE_PARM>: Use 2009 PLACEHOLDER_TYPE_CONSTRAINTS_INFO instead. 2010 (make_constrained_placeholder_type): Set 2011 PLACEHOLDER_TYPE_CONSTRAINTS_INFO instead. 2012 (do_auto_deduction): Clarify comments about the outer_targs 2013 parameter. Rework satisfaction of a placeholder type constraint 2014 to pass in the complete set of template arguments directly to 2015 constraints_satisfied_p. 2016 (splice_late_return_type): Use PLACEHOLDER_TYPE_CONSTRAINTS_INFO 2017 instead. Also rebuild the the constraint info on the new auto. 2018 20192021-03-02 Patrick Palka <ppalka@redhat.com> 2020 2021 * constraint.cc (build_parameter_mapping): Rely on the caller to 2022 determine the in-scope template parameters. 2023 (norm_info::norm_info): Delegate the tsubst_flags_t constructor 2024 to the two-parameter constructor. In the two-parameter 2025 constructor, fold in the definition of make_context, set 2026 initial_parms appropriately, and don't set the now-removed 2027 orig_decl member. 2028 (norm_info::make_context): Remove, now that its only use is 2029 inlined into the caller. 2030 (norm_info::update_context): Adjust call to 2031 build_parameter_mapping to pass in the relevant set of in-scope 2032 template parameters. 2033 (norm_info::ctx_parms): Define this member function. 2034 (norm_info::context): Initialize to NULL_TREE. 2035 (norm_info::orig_decl): Remove this data member. 2036 (norm_info::initial_parms): Define this data member. 2037 (normalize_atom): Adjust call to build_parameter_mapping to pass 2038 in the relevant set of in-scope template parameters. Use 2039 info.initial_parms instead of info.orig_decl. 2040 (normalize_constraint_expression): Take a norm_info object 2041 instead of a bool. Cache the result of normalization. 2042 (tsubst_nested_requirement): Call satisfy_constraint_expression 2043 instead of satisfy_constraint, so that we normalize on demand. 2044 (satisfy_constraint_expression): Handle a NESTED_REQ argument. 2045 Adjust call to normalize_constraint_expression. 2046 (finish_nested_requirement): Set the TREE_TYPE of the NESTED_REQ 2047 to current_template_parms. 2048 (diagnose_nested_requirements): Go through 2049 satisfy_constraint_expression, as with tsubst_nested_requirement. 2050 20512021-03-02 Patrick Palka <ppalka@redhat.com> 2052 2053 * constraint.cc (tsubst_parameter_mapping): Canonicalize the 2054 arguments of a substituted TYPE_ARGUMENT_PACK even if we've 2055 started with a TYPE_ARGUMENT_PACK. 2056 (finish_requires_expr): Don't set DECL_CONTEXT and 2057 CONSTRAINT_VAR_P on each of the introduced parameters here. 2058 * parser.c (cp_parser_requirement_parameter_list): Instead set 2059 these fields earlier, here. 2060 * pt.c (do_auto_deduction): Canonicalize the result of 2061 do_auto_deduction. Pass 'complain' to finish_decltype_type. 2062 20632021-03-02 Patrick Palka <ppalka@redhat.com> 2064 2065 * constraint.cc (tsubst_simple_requirement): Just return 2066 boolean_true_node on success. 2067 (tsubst_type_requirement): Likewise. 2068 (tsubst_compound_requirement): Likewise. 2069 (tsubst_nested_requirement): Likewise. 2070 (tsubst_requirement_body): Remove. 2071 (check_constaint_variables): Rename to ... 2072 (check_constraint_variables): ... this. 2073 (tsubst_constraint_variables): Adjust. 2074 (tsubst_requires_expr): Fold tsubst_requirement_body into here. 2075 20762021-03-01 Nathan Sidwell <nathan@acm.org> 2077 2078 PR c++/99294 2079 * class.c (fixup_type_variants): Propagate mode, precision, 2080 alignment & emptiness. 2081 * module.cc (trees_out::type_node): Use TYPE_ALIGN_RAW. 2082 (trees_in::tree_node): Rematerialize alignment here. 2083 20842021-02-27 Jason Merrill <jason@redhat.com> 2085 2086 PR c++/90333 2087 * parser.c (cp_parser_lambda_declarator_opt): Accept GNU attributes 2088 between () and ->. 2089 20902021-02-26 Jakub Jelinek <jakub@redhat.com> 2091 2092 * parser.c (cp_parser_lambda_declarator_opt): Implement 2093 P1102R2 - Down with ()! Make ()s optional before lambda specifiers 2094 for -std={c,gnu}++2b or with pedwarn in earlier versions. 2095 20962021-02-26 Jakub Jelinek <jakub@redhat.com> 2097 2098 PR c++/95451 2099 * lambda.c (is_lambda_ignored_entity): Before checking for 2100 LAMBDA_FUNCTION_P, use OVL_FIRST. Drop FUNCTION_DECL check. 2101 21022021-02-26 Jason Merrill <jason@redhat.com> 2103 2104 PR c++/98810 2105 * pt.c (tsubst_copy) [VIEW_CONVERT_EXPR]: Add const 2106 to a class non-type template argument that needs it. 2107 21082021-02-26 Patrick Palka <ppalka@redhat.com> 2109 2110 PR c++/98990 2111 * pt.c (splice_late_return_type): Rebuild the entire return type 2112 if we have to adjust the level of an auto within. 2113 (type_uses_auto): Adjust call to find_type_usage. 2114 * type-utils.h (find_type_usage): Revert r10-6571 change that 2115 made this function return a pointer to the auto node. 2116 21172021-02-25 Patrick Palka <ppalka@redhat.com> 2118 2119 PR c++/99213 2120 PR c++/94521 2121 * error.c (dump_scope): Pass TFF_NO_TEMPLATE_BINDINGS instead of 2122 TFF_NO_FUNCTION_ARGUMENTS when dumping a function scope. 2123 21242021-02-25 Patrick Palka <ppalka@redhat.com> 2125 2126 PR c++/99103 2127 * pt.c (is_spec_or_derived): Drop cv-qualifiers from 'etype'. 2128 (maybe_aggr_guide): Fix order of arguments to is_spec_or_derived. 2129 21302021-02-25 Marek Polacek <polacek@redhat.com> 2131 2132 DR 1312 2133 PR c++/99176 2134 * constexpr.c (is_std_construct_at): New overload. 2135 (is_std_allocator_allocate): New overload. 2136 (cxx_eval_call_expression): Use the new overloads. 2137 (cxx_eval_constant_expression): Reject casting 2138 from void * as per DR 1312. Don't check can_convert. 2139 21402021-02-25 Iain Sandoe <iain@sandoe.co.uk> 2141 2142 PR c++/97587 2143 * coroutines.cc (struct param_info): Track rvalue refs. 2144 (morph_fn_to_coro): Track rvalue refs, and call the promise 2145 CTOR with the frame copy of passed parms. 2146 21472021-02-25 Iain Sandoe <iain@sandoe.co.uk> 2148 2149 PR c++/95822 2150 * coroutines.cc (morph_fn_to_coro): Unconditionally remove any 2151 set throwing_cleanup marker. 2152 21532021-02-25 Nathan Sidwell <nathan@acm.org> 2154 2155 PR c++/99166 2156 * module.cc (module_state::inform_cmi_p): Renamed field. 2157 (module_state::do_import): Adjust. 2158 (init_modules, finish_module_processing): Likewise. 2159 (handle_module_option): Likewise. 2160 21612021-02-25 Nathan Sidwell <nathan@acm.org> 2162 2163 PR c++/98318 2164 * mapper-client.cc (module_client::open_module_client): Fix typo 2165 of fd init. 2166 21672021-02-24 Nathan Sidwell <nathan@acm.org> 2168 2169 PR c++/98718 2170 * module.cc (ool): New indirection vector. 2171 (loc_spans::maybe_propagate): Location is not optional. 2172 (loc_spans::open): Likewise. Assert monotonically advancing. 2173 (module_for_ordinary_loc): Use ool indirection vector. 2174 (module_state::write_prepare_maps): Do not count empty macro 2175 expansions. Elide empty spans. 2176 (module_state::write_macro_maps): Skip empty expansions. 2177 (ool_cmp): New qsort comparator. 2178 (module_state::write): Create and destroy ool vector. 2179 (name_pending_imports): Fix dump push/pop. 2180 (preprocess_module): Likewise. Add more dumping. 2181 (preprocessed_module): Likewise. 2182 21832021-02-24 Iain Sandoe <iain@sandoe.co.uk> 2184 2185 PR c++/96251 2186 * coroutines.cc (coro_common_keyword_context_valid_p): Suppress 2187 error reporting when instantiating for a constexpr. 2188 21892021-02-23 Nathan Sidwell <nathan@acm.org> 2190 2191 PR c++/99208 2192 * decl.c (name_unnamed_type): Check DECL identity, not IDENTIFIER 2193 identity. 2194 21952021-02-23 Patrick Palka <ppalka@redhat.com> 2196 2197 PR c++/95468 2198 * pt.c (tsubst_copy_and_build) <case BASELINK>: New case, copied 2199 over from tsubst_copy. 2200 22012021-02-23 Patrick Palka <ppalka@redhat.com> 2202 2203 * pt.c (instantiation_dependent_expression_p): Check 2204 processing_template_decl before calling 2205 potential_constant_expression. 2206 22072021-02-22 Nathan Sidwell <nathan@acm.org> 2208 2209 PR c++/99174 2210 * module.cc (struct module_state): Add visited_p flag. 2211 (name_pending_imports): Use it to avoid duplicate requests. 2212 (preprocess_module): Don't read preprocessor state if we failed to 2213 load a module's config. 2214 22152021-02-22 Nathan Sidwell <nathan@acm.org> 2216 2217 PR c++/99153 2218 * decl.c (duplicate_decls): Move DECL_MODULE_IMPORT_P propagation 2219 to common-path. 2220 * module.cc (set_defining_module): Add assert. 2221 22222021-02-19 Nathan Sidwell <nathan@acm.org> 2223 2224 PR c++/98741 2225 * module.cc (pending_imports): New. 2226 (declare_module): Adjust test condition. 2227 (name_pending_imports): New. 2228 (preprocess_module): Reimplement using pending_imports. 2229 (preprocessed_module): Move name-getting to name_pending_imports. 2230 * name-lookup.c (append_imported_binding_slot): Assert module 2231 ordering is increasing. 2232 22332021-02-19 Nathan Sidwell <nathan@acm.org> 2234 2235 * module.cc (note_cmis): New. 2236 (struct module_state): Add inform_read_p bit. 2237 (module_state::do_import): Inform of CMI location, if enabled. 2238 (init_modules): Canonicalize note_cmis entries. 2239 (handle_module_option): Handle -flang-info-module-read=FOO. 2240 22412021-02-19 Jason Merrill <jason@redhat.com> 2242 2243 PR c++/96926 2244 * call.c (perfect_conversion_p): Limit rvalueness 2245 test to reference bindings. 2246 22472021-02-19 Jason Merrill <jason@redhat.com> 2248 2249 PR c++/96926 2250 * call.c (perfect_conversion_p): New. 2251 (perfect_candidate_p): New. 2252 (add_candidates): Ignore templates after a perfect non-template. 2253 22542021-02-18 Nathan Sidwell <nathan@acm.org> 2255 2256 PR c++/99023 2257 * module.cc (canonicalize_header_name): Use 2258 cpp_probe_header_unit. 2259 (maybe_translate_include): Fix note_includes comparison. 2260 (init_modules): Fix note_includes string termination. 2261 22622021-02-18 Jakub Jelinek <jakub@redhat.com> 2263 2264 PR c++/99132 2265 * cp-gimplify.c (cp_genericize_r) <case CALL_EXPR>: Use 2266 cp_get_callee_fndecl_nofold instead of cp_get_callee_fndecl to check 2267 for immediate function calls. 2268 22692021-02-17 Nathan Sidwell <nathan@acm.org> 2270 2271 PR c++/99023 2272 * module.cc (struct macro_export): Add GTY markers. 2273 (macro_exports): Likewise, us a va_gc Vector. 2274 22752021-02-17 Jakub Jelinek <jakub@redhat.com> 2276 2277 PR sanitizer/99106 2278 * init.c (build_zero_init_1): For flexible array members just return 2279 NULL_TREE instead of returning empty CONSTRUCTOR with non-complete 2280 ARRAY_TYPE. 2281 22822021-02-17 Nathan Sidwell <nathan@acm.org> 2283 2284 PR c++/99116 2285 * name-lookup.c (do_pushdecl): Don't peek under template_parm 2286 bindings here ... 2287 (set_identifier_type_value_with_scope): ... or here. 2288 (do_pushtag): Only set_identifier_type_value_with_scope at 2289 non-class template parm scope, and use parent scope. 2290 22912021-02-17 Nathan Sidwell <nathan@acm.org> 2292 2293 PR c++/99071 2294 * name-lookup.c (maybe_record_mergeable_decl): Deref the correct 2295 pointer. 2296 22972021-02-17 Patrick Palka <ppalka@redhat.com> 2298 2299 PR debug/96997 2300 PR c++/94034 2301 * tree.c (build_aggr_init_expr): Revert r10-7718 change. 2302 23032021-02-12 Nathan Sidwell <nathan@acm.org> 2304 2305 * module.cc (module_state::write_cluster): Check bindings for 2306 imported using-decls. 2307 23082021-02-12 Nathan Sidwell <nathan@acm.org> 2309 2310 PR c++/99040 2311 * module.cc (trees_in::decl_value): Call add_module_namespace_decl 2312 for new namespace-scope entities. 2313 (module_state::read_cluster): Don't call add_module_decl here. 2314 * name-lookup.h (add_module_decl): Rename to ... 2315 (add_module_namespace_decl): ... this. 2316 * name-lookup.c (newbinding_bookkeeping): Move into ... 2317 (do_pushdecl): ... here. Its only remaining caller. 2318 (add_module_decl): Rename to ... 2319 (add_module_namespace_decl): ... here. Add checking-assert for 2320 circularity. Don't call newbinding_bookkeeping, just extern_c 2321 checking and incomplete var checking. 2322 23232021-02-12 Nathan Sidwell <nathan@acm.org> 2324 2325 PR c++/99039 2326 PR c++/99040 2327 * cp-tree.h (CPTI_GLOBAL_TYPE): Delete. 2328 (global_type_node): Delete. 2329 (IDENTIFIER_TYPE_VALUE): Delete. 2330 (IDENTIFIER_HAS_TYPE_VALUE): Delete. 2331 (get_type_value): Delete. 2332 * name-lookup.h (identifier_type_value): Delete. 2333 * name-lookup.c (check_module_override): Don't 2334 SET_IDENTIFIER_TYPE_VALUE here. 2335 (do_pushdecl): Nor here. 2336 (identifier_type_value_1, identifier_type_value): Delete. 2337 (set_identifier_type_value_with_scope): Only 2338 SET_IDENTIFIER_TYPE_VALUE for local and class scopes. 2339 (pushdecl_nanmespace_level): Remove shadow stack nadgering. 2340 (do_pushtag): Use REAL_IDENTIFIER_TYPE_VALUE. 2341 * call.c (check_dtor_name): Use lookup_name. 2342 * decl.c (cxx_init_decl_processing): Drop global_type_node. 2343 * decl2.c (cplus_decl_attributes): Don't SET_IDENTIFIER_TYPE_VALUE 2344 here. 2345 * init.c (get_type_value): Delete. 2346 * pt.c (instantiate_class_template_1): Don't call pushtag or 2347 SET_IDENTIFIER_TYPE_VALUE here. 2348 (tsubst): Assert never an identifier. 2349 (dependent_type_p): Drop global_type_node assert. 2350 * typeck.c (error_args_num): Don't use IDENTIFIER_HAS_TYPE_VALUE 2351 to determine ctorness. 2352 23532021-02-12 Jakub Jelinek <jakub@redhat.com> 2354 2355 PR c++/97742 2356 * parser.c (cp_parser_requirement_seq): Stop iterating after reaching 2357 CPP_EOF. 2358 23592021-02-12 Jason Merrill <jason@redhat.com> 2360 2361 PR c++/97246 2362 PR c++/94546 2363 * pt.c (extract_fnparm_pack): Check DECL_PACK_P here. 2364 (register_parameter_specializations): Not here. 2365 23662021-02-11 Marek Polacek <polacek@redhat.com> 2367 2368 PR c++/95888 2369 * pt.c (lookup_template_class_1): Pass tf_none to tsubst when looking 2370 for the partial instantiation. 2371 23722021-02-11 Jakub Jelinek <jakub@redhat.com> 2373 2374 PR c++/99033 2375 * init.c (build_zero_init_1): Handle zero initialiation of 2376 flexible array members like initialization of [0] arrays. 2377 Use integer_minus_onep instead of comparison to integer_minus_one_node 2378 and integer_zerop instead of comparison against size_zero_node. 2379 Formatting fixes. 2380 23812021-02-11 Marek Polacek <polacek@redhat.com> 2382 2383 PR c++/99063 2384 * semantics.c (finish_do_stmt): Check for unexpanded parameter packs. 2385 23862021-02-11 Patrick Palka <ppalka@redhat.com> 2387 2388 PR c++/97582 2389 * name-lookup.c (op_unqualified_lookup): Handle an ambiguous 2390 lookup result by discarding it if the first element is a 2391 class-scope declaration, otherwise return it. 2392 (push_operator_bindings): Handle an ambiguous lookup result by 2393 doing push_local_binding on each element in the list. 2394 23952021-02-11 Marek Polacek <polacek@redhat.com> 2396 2397 * parser.c (cp_parser_selection_statement): Use vec_free. 2398 23992021-02-10 Jakub Jelinek <jakub@redhat.com> 2400 2401 PR c++/98988 2402 PR c++/99031 2403 * constexpr.c: Include cgraph.h. 2404 (cxx_eval_call_expression): Call varpool_node::finalize_decl on 2405 heap artificial vars. 2406 (cxx_eval_outermost_constant_expr): Remove varpool nodes for 2407 heap artificial vars. 2408 24092021-02-10 Nathan Sidwell <nathan@acm.org> 2410 2411 PR c++/99030 2412 * pt.c (tsubst_copy) [VAR_DECL]: For a DECL_LOCAL_DECL_P T is the 2413 answer if there's no local specialization. 2414 24152021-02-09 Nathan Sidwell <nathan@acm.org> 2416 2417 PR c++/98944 2418 * module.cc (module_state::is_rooted): Rename to ... 2419 (module_state::has_location): ... here. Adjust callers. 2420 (module_state::read_partitions): Adjust validity check. 2421 Don't overwrite a known location. 2422 24232021-02-09 Jason Merrill <jason@redhat.com> 2424 2425 PR c++/96905 2426 * pt.c (mark_decl_instantiated): Exit early if consteval. 2427 24282021-02-09 Jason Merrill <jason@redhat.com> 2429 2430 PR c++/98326 2431 PR c++/20408 2432 * cp-gimplify.c (simple_empty_class_p): Don't touch an invisiref 2433 parm. 2434 24352021-02-09 Jason Merrill <jason@redhat.com> 2436 2437 PR c++/98994 2438 PR c++/97566 2439 * constexpr.c (cxx_eval_store_expression): Only skip empty fields in 2440 RECORD_TYPE. 2441 24422021-02-08 Nathan Sidwell <nathan@acm.org> 2443 2444 * decl.c (start_cleanup_fn): Push function into 2445 namespace. 2446 24472021-02-08 Nathan Sidwell <nathan@acm.org> 2448 2449 PR c++/98531 2450 * cp-tree.h (push_abi_namespace, pop_abi_namespace): Declare. 2451 * decl.c (push_abi_namespace, pop_abi_namespace): Moved 2452 from rtti.c, add default namespace arg. 2453 (check_redeclaration_exception_specification): Allow a lazy 2454 builtin's eh spec to differ from an lready-declared user 2455 declaration. 2456 (declare_global_var): Use push/pop_abi_namespace. 2457 (get_atexit_node): Push the fndecl into a namespace. 2458 * rtti.c (push_abi_namespace, pop_abi_namespace): Moved to 2459 decl.c. 2460 24612021-02-08 Marek Polacek <polacek@redhat.com> 2462 2463 * cp-tree.h (CLASSTYPE_TI_TEMPLATE): Fix typo. 2464 24652021-02-05 Marek Polacek <polacek@redhat.com> 2466 2467 PR c++/98947 2468 * call.c (build_conditional_expr_1): Don't call mark_lvalue_use 2469 on arg2/arg3. 2470 * expr.c (mark_use) <case MODIFY_EXPR>: Don't check read_p when 2471 issuing the -Wvolatile warning. Only set TREE_THIS_VOLATILE if 2472 a warning was emitted. 2473 24742021-02-05 Marek Polacek <polacek@redhat.com> 2475 2476 PR c++/96462 2477 * name-lookup.c (lookup_using_decl): Hoist the destructor check. 2478 24792021-02-05 Jakub Jelinek <jakub@redhat.com> 2480 2481 PR c++/97878 2482 * decl.c (check_array_initializer): For structured bindings, require 2483 the array type to be complete. 2484 24852021-02-04 Jason Merrill <jason@redhat.com> 2486 2487 PR c++/98717 2488 * constraint.cc (build_concept_check_arguments): Remove assert. 2489 (build_concept_check): Allow empty args. 2490 24912021-02-04 Tom Greenslade (thomgree) <thomgree@cisco.com> 2492 2493 PR c++/90926 2494 * call.c (can_convert_array): Extend to handle all valid aggregate 2495 initializers of an array; including by string literals, not just by 2496 brace-init-list. 2497 (build_aggr_conv): Call can_convert_array more often, not just in 2498 brace-init-list case. 2499 * typeck2.c (array_string_literal_compatible_p): New function. 2500 (digest_init_r): call array_string_literal_compatible_p 2501 * cp-tree.h: (array_string_literal_compatible_p): Declare. 2502 25032021-02-04 Jason Merrill <jason@redhat.com> 2504 2505 PR c++/98802 2506 * pt.c (do_class_deduction): No aggregate guide if any_dguides_p. 2507 25082021-02-04 Jason Merrill <jason@redhat.com> 2509 2510 PR c++/95192 2511 * pt.c (tsubst_attribute): Handle error. 2512 (apply_late_template_attributes): Return false on error. 2513 (tsubst_function_decl): Check its return value. 2514 (tsubst_decl): Likewise. 2515 (push_template_decl): Assert current_template_parms. 2516 (tsubst_template_decl): Set current_template_parms. 2517 25182021-02-03 Marek Polacek <polacek@redhat.com> 2519 2520 PR c++/98951 2521 * call.c (struct z_candidate): Mark rewritten and reversed as const. 2522 (struct NonPublicField): Mark operator() as const. 2523 (struct NonTrivialField): Likewise. 2524 25252021-02-03 Jason Merrill <jason@redhat.com> 2526 2527 PR c++/98926 2528 PR c++/98570 2529 * pt.c (spec_hasher::equal): Set processing_template_decl. 2530 * Make-lang.in (check-g++-strict-gc): Add --param 2531 hash-table-verification-limit=10000. 2532 25332021-02-03 Marek Polacek <polacek@redhat.com> 2534 2535 PR c++/98899 2536 * parser.c (cp_parser_class_specifier_1): Use any possible 2537 DEFPARSE_INSTANTIATIONS to update DEFERRED_NOEXCEPT_PATTERN. 2538 (cp_parser_save_noexcept): Initialize DEFPARSE_INSTANTIATIONS. 2539 * pt.c (tsubst_exception_specification): Stash new_specs into 2540 DEFPARSE_INSTANTIATIONS. 2541 * tree.c (fixup_deferred_exception_variants): Use 2542 UNPARSED_NOEXCEPT_SPEC_P. 2543 25442021-02-02 Jason Merrill <jason@redhat.com> 2545 2546 PR c++/98929 2547 PR c++/96199 2548 * error.c (dump_expr): Ignore dummy object. 2549 * pt.c (tsubst_baselink): Handle dependent scope. 2550 25512021-02-01 Patrick Palka <ppalka@redhat.com> 2552 2553 PR c++/98295 2554 * constexpr.c (cxx_eval_array_reference): Also set 2555 new_ctx.object when setting new_ctx.ctor. 2556 25572021-02-01 Marek Polacek <polacek@redhat.com> 2558 2559 PR c++/98355 2560 * parser.c (cp_parser_has_attribute_expression): Use 2561 uses_template_parms instead of type_dependent_expression_p. 2562 25632021-02-01 Jason Merrill <jason@redhat.com> 2564 2565 PR c++/98570 2566 * cp-tree.h: Declare it. 2567 * pt.c (comparing_dependent_aliases): New flag. 2568 (template_args_equal, spec_hasher::equal): Set it. 2569 (dependent_alias_template_spec_p): Assert that we don't 2570 get non-types other than error_mark_node. 2571 (instantiate_alias_template): SET_TYPE_STRUCTURAL_EQUALITY 2572 on complex alias specializations. Set TYPE_DEPENDENT_P here. 2573 (tsubst_decl): Not here. 2574 * module.cc (module_state::read_cluster): Set 2575 comparing_dependent_aliases instead of 2576 comparing_specializations. 2577 * tree.c (cp_tree_equal): Remove comparing_specializations 2578 module handling. 2579 * typeck.c (structural_comptypes): Adjust. 2580 (comptypes): Remove comparing_specializations handling. 2581 25822021-01-29 Nathan Sidwell <nathan@acm.org> 2583 2584 PR c++/98843 2585 * module.cc (module_state_config): Add num_entities field. 2586 (module_state::read_entities): The entity_ary span is 2587 already allocated. 2588 (module_state::write_config): Write num_entities. 2589 (module_state::read_config): Read num_entities. 2590 (module_state::write): Set config's num_entities. 2591 (module_state::read_initial): Allocate the entity ary 2592 span here. 2593 (module_state::read_language): Do not set entity_lwm 2594 here. 2595 25962021-01-29 Marek Polacek <polacek@redhat.com> 2597 2598 PR c++/96137 2599 * parser.c (cp_parser_class_name): If parser->scope is 2600 error_mark_node, return it, otherwise continue. 2601 26022021-01-28 Jakub Jelinek <jakub@redhat.com> 2603 2604 PR c++/98841 2605 * typeck.c (build_x_indirect_ref): For *this, return current_class_ref. 2606 26072021-01-28 Jakub Jelinek <jakub@redhat.com> 2608 2609 PR c++/33661 2610 PR c++/98847 2611 * decl.c (cp_finish_decl): For register vars with asmspec in templates 2612 call set_user_assembler_name and set DECL_HARD_REGISTER. 2613 * pt.c (tsubst_expr): When instantiating DECL_HARD_REGISTER vars, 2614 pass asmspec_tree to cp_finish_decl. 2615 26162021-01-28 Nathan Sidwell <nathan@acm.org> 2617 2618 PR c++/98770 2619 * module.cc (trees_out::decl_value): Swap is_typedef & TYPE_NAME 2620 check order. 2621 (trees_in::decl_value): Do typedef frobbing only when installing 2622 a new typedef, adjust is_matching_decl call. Swap is_typedef 2623 & TYPE_NAME check. 2624 (trees_in::is_matching_decl): Add is_typedef parm. Adjust variable 2625 names and deal with typedef checking. 2626 26272021-01-27 Jason Merrill <jason@redhat.com> 2628 2629 PR c++/97874 2630 * name-lookup.c (lookup_using_decl): Clean up handling 2631 of dependency and inherited constructors. 2632 (finish_nonmember_using_decl): Handle DECL_DEPENDENT_P. 2633 * pt.c (tsubst_expr): Handle DECL_DEPENDENT_P. 2634 26352021-01-26 Jason Merrill <jason@redhat.com> 2636 2637 PR c++/97474 2638 * call.c (type_passed_as): Don't mark invisiref restrict. 2639 26402021-01-26 Jason Merrill <jason@redhat.com> 2641 2642 PR c++/97566 2643 PR c++/98463 2644 * class.c (layout_class_type): An empty field gets size 0. 2645 (is_empty_field): New. 2646 (check_bases): Check it. 2647 * cp-tree.h (is_empty_field): Declare it. 2648 * constexpr.c (cxx_eval_store_expression): Check it. 2649 (cx_check_missing_mem_inits): Likewise. 2650 * init.c (perform_member_init): Likewise. 2651 * typeck2.c (process_init_constructor_record): Likewise. 2652 26532021-01-25 Martin Sebor <msebor@redhat.com> 2654 2655 PR c++/98646 2656 * cvt.c (cp_fold_convert): Propagate TREE_NO_WARNING. 2657 26582021-01-25 Jason Merrill <jason@redhat.com> 2659 2660 PR c++/98463 2661 * constexpr.c (get_or_insert_ctor_field): Add check. 2662 (cxx_eval_store_expression): Handle discontinuity of refs. 2663 26642021-01-23 Anthony Sharp <anthonysharp15@gmail.com> 2665 2666 * call.c (complain_about_access): Altered function. 2667 * cp-tree.h (complain_about_access): Changed parameters of function. 2668 (get_parent_with_private_access): Declared new function. 2669 * search.c (get_parent_with_private_access): Defined new function. 2670 * semantics.c (enforce_access): Modified function. 2671 * typeck.c (complain_about_unrecognized_member): Updated function 2672 arguments in complain_about_access. 2673 26742021-01-23 Patrick Palka <ppalka@redhat.com> 2675 2676 PR c++/97399 2677 * cp-tree.h (shared_member_p): Adjust declaration. 2678 * parser.c (cp_parser_init_declarator): If the storage class 2679 specifier is sc_static, pass true for static_p to 2680 cp_parser_declarator. 2681 (cp_parser_direct_declarator): Don't do inject_this_parm when 2682 the declarator is a friend. 2683 * search.c (shared_member_p): Change return type to bool and 2684 adjust function body accordingly. Return false for a dependent 2685 USING_DECL instead of aborting. 2686 * semantics.c (finish_qualified_id_expr): Rely on shared_member_p 2687 even when type-dependent. 2688 26892021-01-22 Marek Polacek <polacek@redhat.com> 2690 2691 PR c++/96623 2692 * parser.c (inject_parm_decls): Remove a redundant assignment. 2693 (cp_parser_class_specifier_1): Clear current_class_{ptr,ref} 2694 before calling inject_parm_decls. 2695 26962021-01-22 Jason Merrill <jason@redhat.com> 2697 2698 PR c++/98744 2699 * call.c (make_base_init_ok): Use DECL_HAS_VTT_PARM_P. 2700 27012021-01-22 Jakub Jelinek <jakub@redhat.com> 2702 2703 PR sanitizer/95693 2704 * init.c (build_zero_init_1): Revert the 2018-03-06 change to 2705 return build_zero_cst for reference types. 2706 * typeck2.c (process_init_constructor_record): Instead call 2707 build_zero_cst here during error recovery instead of build_zero_init. 2708 27092021-01-22 Marek Polacek <polacek@redhat.com> 2710 2711 PR c++/98545 2712 * mangle.c (write_member_name): Emit abi_warn_or_compat_version_crosses 2713 warnings regardless of abi_version_at_least. 2714 (write_expression): When the expression is a dependent name 2715 and an operator name, write "on" before writing its name. 2716 27172021-01-22 Marek Polacek <polacek@redhat.com> 2718 2719 PR c++/97966 2720 * pt.c (instantiate_class_template_1): Instantiate members 2721 marked with attribute used only after we're done instantiating 2722 the class. 2723 27242021-01-21 Patrick Palka <ppalka@redhat.com> 2725 2726 PR c++/71879 2727 * semantics.c (finish_decltype_type): Set up a cp_unevaluated 2728 sentinel at the start of the function. Remove a now-redundant 2729 manual adjustment of cp_unevaluated_operand. 2730 27312021-01-21 Nathan Sidwell <nathan@acm.org> 2732 2733 PR c++/98624 2734 * module.cc (depset::hash::find_dependencies): Add 2735 module arg. 2736 (trees_out::core_vals): Check state before calling 2737 write_location. 2738 (sort_cluster, module_state::write): Adjust 2739 find_dependencies call. 2740 27412021-01-21 Jakub Jelinek <jakub@redhat.com> 2742 2743 PR c++/98672 2744 * constexpr.c (check_for_return_continue_data): Add break_stmt member. 2745 (check_for_return_continue): Also look for BREAK_STMT. Handle 2746 SWITCH_STMT by ignoring break_stmt from its body. 2747 (potential_constant_expression_1) <case FOR_STMT>, 2748 <case WHILE_STMT>: If the condition isn't constant true, check if 2749 the loop body can contain a return stmt. 2750 <case SWITCH_STMT>: Adjust check_for_return_continue_data initializer. 2751 <case IF_STMT>: If recursion with tf_none is successful, 2752 merge *jump_target from the branches - returns with highest priority, 2753 breaks or continues lower. If then branch is potentially constant and 2754 doesn't return, check the else branch if it could return, break or 2755 continue. 2756 27572021-01-21 Nathan Sidwell <nathan@acm.org> 2758 2759 PR c++/98530 2760 * name-lookup.c (lookup_class_binding): Rearrange a stat-hack. 2761 27622021-01-20 Nathan Sidwell <nathan@acm.org> 2763 2764 * module.cc (bytes_in::i, bytes_in::wi): Avoid left shift of 2765 signed type. 2766 27672021-01-20 Patrick Palka <ppalka@redhat.com> 2768 2769 PR c++/95434 2770 * pt.c (tsubst) <case TEMPLATE_TYPE_PARM>: If tsubsting 2771 CLASS_PLACEHOLDER_TEMPLATE yields a TEMPLATE_TEMPLATE_PARM, 2772 adjust to its TEMPLATE_TEMPLATE_PARM_TEMPLATE_DECL. 2773 27742021-01-20 Patrick Palka <ppalka@redhat.com> 2775 2776 PR c++/82613 2777 * parser.c (cp_parser_class_head): Defer access checking when 2778 parsing the base-clause until all bases are seen and attached 2779 to the class type. 2780 * pt.c (instantiate_class_template): Likewise when substituting 2781 into dependent bases. 2782 27832021-01-20 Jakub Jelinek <jakub@redhat.com> 2784 2785 PR c++/98742 2786 * semantics.c (finish_omp_clauses) <case OMP_CLAUSE_DETACH>: If 2787 error_operand_p, remove clause without further checking. Check 2788 for non-NULL TYPE_NAME. 2789 27902021-01-19 Marek Polacek <polacek@redhat.com> 2791 2792 PR c++/98659 2793 * pt.c (maybe_instantiate_noexcept): Return false if FN is 2794 error_mark_node. 2795 27962021-01-19 Marek Polacek <polacek@redhat.com> 2797 2798 PR c++/98687 2799 * name-lookup.c (push_using_decl_bindings): New, broken out of... 2800 (finish_nonmember_using_decl): ...here. 2801 * name-lookup.h (push_using_decl_bindings): Update declaration. 2802 * pt.c (tsubst_expr): Update the call to push_using_decl_bindings. 2803 28042021-01-19 Patrick Palka <ppalka@redhat.com> 2805 2806 PR c++/41437 2807 PR c++/58993 2808 * search.c (friend_accessible_p): If scope is a hidden friend 2809 defined inside a dependent class, consider access from the 2810 class. 2811 * parser.c (cp_parser_late_parsing_for_member): Don't push a 2812 dk_no_check access state. 2813 28142021-01-19 Marek Polacek <polacek@redhat.com> 2815 2816 PR c++/98333 2817 * parser.c (cp_parser_class_specifier_1): Perform late-parsing 2818 of NSDMIs before late-parsing of noexcept-specifiers. 2819 28202021-01-19 Nathan Sidwell <nathan@acm.org> 2821 2822 * module.cc (identifier): Merge overloads. 2823 28242021-01-19 Nathan Sidwell <nathan@acm.org> 2825 2826 PR c++/98624 2827 * module.cc (trees_out::write_location): Make static. 2828 28292021-01-16 Kwok Cheung Yeung <kcy@codesourcery.com> 2830 2831 * parser.c (cp_parser_omp_clause_detach): New. 2832 (cp_parser_omp_all_clauses): Handle PRAGMA_OMP_CLAUSE_DETACH. 2833 (OMP_TASK_CLAUSE_MASK): Add mask for PRAGMA_OMP_CLAUSE_DETACH. 2834 * pt.c (tsubst_omp_clauses): Handle OMP_CLAUSE_DETACH clause. 2835 * semantics.c (finish_omp_clauses): Handle OMP_CLAUSE_DETACH clause. 2836 Prevent use of detach with mergeable and overriding the data sharing 2837 mode of the event handle. 2838 28392021-01-15 Nathan Sidwell <nathan@acm.org> 2840 2841 PR c++/98538 2842 * tree.c (cp_build_qualified_type_real): Propagate an array's 2843 dependentness to the copy, if known. 2844 28452021-01-15 Jason Merrill <jason@redhat.com> 2846 2847 PR c++/98642 2848 * call.c (unsafe_return_slot_p): Return int. 2849 (init_by_return_slot_p): Split out from... 2850 (unsafe_copy_elision_p): ...here. 2851 (unsafe_copy_elision_p_opt): New name for old meaning. 2852 (build_over_call): Adjust. 2853 (make_safe_copy_elision): New. 2854 * typeck2.c (split_nonconstant_init_1): Elide copy from safe 2855 list-initialization. 2856 * cp-tree.h: Adjust. 2857 28582021-01-15 Jason Merrill <jason@redhat.com> 2859 2860 * call.c (base_ctor_for, make_base_init_ok): New. 2861 (build_over_call): Use make_base_init_ok. 2862 28632021-01-15 Jason Merrill <jason@redhat.com> 2864 2865 PR c++/63707 2866 * tree.c (build_vec_init_expr): Don't call build_vec_init_elt 2867 if we got a CONSTRUCTOR. 2868 28692021-01-15 Nathan Sidwell <nathan@acm.org> 2870 2871 PR c++/98591 2872 * lang-specs.h: Fix handling of -fmodule-only with -fsyntax-only. 2873 28742021-01-14 Jason Merrill <jason@redhat.com> 2875 2876 * typeck2.c (process_init_constructor_record): Use fldtype 2877 variable consistently. 2878 28792021-01-14 Nathan Sidwell <nathan@acm.org> 2880 2881 PR c++/98372 2882 * tree.c (cp_tree_equal): Correct map_context logic. 2883 28842021-01-13 Marek Polacek <polacek@redhat.com> 2885 2886 PR c++/98231 2887 * name-lookup.c (push_using_decl_bindings): New. 2888 * name-lookup.h (push_using_decl_bindings): Declare. 2889 * pt.c (tsubst_expr): Call push_using_decl_bindings. 2890 28912021-01-13 Nathan Sidwell <nathan@acm.org> 2892 2893 PR c++/98626 2894 * module.cc (module_add_import_initializers): Pass a 2895 zero-element argument vector. 2896 28972021-01-12 Patrick Palka <ppalka@redhat.com> 2898 2899 PR c++/98611 2900 * tree.c (cp_walk_subtrees) <case TEMPLATE_TYPE_PARM>: Visit 2901 the template of a CTAD placeholder. 2902 29032021-01-12 Marek Polacek <polacek@redhat.com> 2904 2905 PR c++/98620 2906 * typeck2.c (process_init_constructor_record): Don't emit 2907 -Wmissing-field-initializers warnings in unevaluated contexts. 2908 29092021-01-11 Jakub Jelinek <jakub@redhat.com> 2910 2911 PR c++/98481 2912 * class.c (find_abi_tags_r): Set *walk_subtrees to 2 instead of 1 2913 for types. 2914 (mark_abi_tags_r): Likewise. 2915 * decl2.c (min_vis_r): Likewise. 2916 * tree.c (cp_walk_subtrees): If *walk_subtrees_p is 2, look through 2917 typedefs. 2918 29192021-01-08 Patrick Palka <ppalka@redhat.com> 2920 2921 PR c++/98551 2922 * constexpr.c (cxx_eval_call_expression): Check CLASS_TYPE_P 2923 instead of AGGREGATE_TYPE_P before calling replace_result_decl. 2924 29252021-01-08 Patrick Palka <ppalka@redhat.com> 2926 2927 PR c++/98515 2928 * semantics.c (check_accessibility_of_qualified_id): Punt if 2929 we're checking access of a scoped non-static member inside a 2930 class template. 2931 29322021-01-07 Jakub Jelinek <jakub@redhat.com> 2933 2934 PR c++/98329 2935 * pt.c (tsubst_copy) <case BIT_CAST_EXPR>: Don't call 2936 cp_build_bit_cast here, instead just build_min a BIT_CAST_EXPR and set 2937 its location. 2938 (tsubst_copy_and_build): Handle BIT_CAST_EXPR. 2939 29402021-01-07 Marek Polacek <polacek@redhat.com> 2941 2942 PR c++/98441 2943 * decl.c (grokdeclarator): Move the !funcdecl_p check inside the 2944 !late_return_type block. 2945 29462021-01-07 Jason Merrill <jason@redhat.com> 2947 2948 * constexpr.c (cxx_bind_parameters_in_call): Add comment. 2949 (cxx_eval_store_expression): Add comment. 2950 29512021-01-07 Jason Merrill <jason@redhat.com> 2952 2953 * call.c (has_next): Factor out from... 2954 (next_conversion): ...here. 2955 (strip_standard_conversion): And here. 2956 (is_subseq): And here. 2957 (build_conv): Check it. 2958 (standard_conversion): Don't call build_conv 2959 for ck_identity. 2960 29612021-01-06 Martin Sebor <msebor@redhat.com> 2962 2963 PR c++/95768 2964 * error.c (dump_expr): Call c_pretty_printer::unary_expression. 2965 29662021-01-05 Patrick Palka <ppalka@redhat.com> 2967 2968 * pt.c (unify) <case TEMPLATE_PARM_INDEX>: After walking into 2969 the type of the NTTP, substitute into the type again. If the 2970 type is still dependent, don't unify the NTTP. 2971 29722021-01-05 Jakub Jelinek <jakub@redhat.com> 2973 2974 * Make-lang.in (cc1plus-checksum, cc1plus$(exeext): Add 2975 $(CODYLIB) after $(BACKEND). 2976 29772021-01-05 Jakub Jelinek <jakub@redhat.com> 2978 2979 PR c++/98469 2980 * constexpr.c (cxx_eval_constant_expression) <case BIT_CAST_EXPR>: 2981 Punt if lval is true. 2982 * semantics.c (cp_build_bit_cast): Call get_target_expr_sfinae on 2983 the result if it has a class type. 2984 29852021-01-05 Marek Polacek <polacek@redhat.com> 2986 2987 PR c++/82099 2988 * pt.c (resolve_overloaded_unification): Call 2989 maybe_instantiate_noexcept after instantiating the function 2990 decl. 2991 29922021-01-05 Nathan Sidwell <nathan@acm.org> 2993 2994 * parser.c (cp_parser_module_declaration): Alter diagnostic 2995 text to say where is permissable. 2996 29972021-01-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> 2998 2999 PR c++/98316 3000 * Make-lang.in (cc1plus$(exeext)): Add $(CODYLIB), $(NETLIBS). 3001 30022021-01-02 Jan Hubicka <jh@suse.cz> 3003 3004 * cp-tree.h (cp_tree_c_finish_parsing): Declare. 3005 * decl2.c (c_parse_final_cleanups): Call cp_tree_c_finish_parsing. 3006 * tree.c (cp_tree_c_finish_parsing): New function. 3007 30082021-01-01 Jakub Jelinek <jakub@redhat.com> 3009 3010 * ChangeLog-2020: Rotate ChangeLog. New file. 3011 3012 3013Copyright (C) 2021 Free Software Foundation, Inc. 3014 3015Copying and distribution of this file, with or without modification, 3016are permitted in any medium without royalty provided the copyright 3017notice and this notice are preserved. 3018