Daily bump.
[official-gcc.git] / gcc / cp / ChangeLog
blobe6a6fbd1eaa810ba580e35c97058d2fbe947a3a7
1 2024-03-04  Nathaniel Shead  <nathanieloshead@gmail.com>
3         * name-lookup.cc (walk_module_binding): Remove completed FIXME.
4         (do_nonmember_using_decl): Mark redeclared entities as exported
5         when needed. Check for re-exporting internal linkage types.
7 2024-03-01  Patrick Palka  <ppalka@redhat.com>
9         PR c++/104919
10         PR c++/106009
11         * module.cc (depset::hash::sneakoscope): Remove.
12         (trees_out::decl_node): Always add a dependency on a local type.
13         (depset::hash::find_dependencies): Remove sneakoscope stuff.
15 2024-03-01  Nathaniel Shead  <nathanieloshead@gmail.com>
17         PR c++/114170
18         * module.cc (has_definition): Fall back to DECL_INITIALIZED_P
19         when DECL_INITIAL is not set on a template.
20         (module_state::write_inits): Only increment count when
21         initializers are actually written.
23 2024-03-01  Nathaniel Shead  <nathanieloshead@gmail.com>
25         PR c++/114005
26         * init.cc (create_temporary_var): Use current_scope instead of
27         current_function_decl.
29 2024-03-01  Patrick Palka  <ppalka@redhat.com>
31         * decl.cc (maybe_register_incomplete_var): Restrict second
32         branch to static data members from a not-yet-complete class.
34 2024-03-01  Marek Polacek  <polacek@redhat.com>
36         PR c++/110358
37         PR c++/109642
38         * call.cc (no_dangling_p): New.
39         (reference_like_class_p): Use it.
40         (do_warn_dangling_reference): Use it.  Don't warn when the function
41         or its enclosing class has attribute gnu::no_dangling.
42         * tree.cc (cxx_gnu_attributes): Add gnu::no_dangling.
43         (handle_no_dangling_attribute): New.
45 2024-03-01  Patrick Palka  <ppalka@redhat.com>
47         PR c++/110025
48         PR c++/114138
49         * cp-tree.h (make_cast_auto): Declare.
50         * parser.cc (cp_parser_functional_cast): If the type is an auto,
51         replace it with a level-less one via make_cast_auto.
52         * pt.cc (find_parameter_packs_r): Don't treat level-less auto
53         as a type parameter pack.
54         (tsubst) <case TEMPLATE_TYPE_PARM>: Generalize CTAD placeholder
55         auto handling to all level-less autos.
56         (make_cast_auto): Define.
57         (do_auto_deduction): Handle replacement of a level-less auto.
59 2024-03-01  Jakub Jelinek  <jakub@redhat.com>
61         PR c++/92687
62         * decl.cc (lookup_decomp_type): Return NULL_TREE if decomp_type_table
63         doesn't have entry for V.
64         * semantics.cc (finish_decltype_type): If ptds.saved, assert
65         DECL_HAS_VALUE_EXPR_P is true and decide on tuple vs. non-tuple based
66         on if lookup_decomp_type is NULL or not.
68 2024-02-29  Marek Polacek  <polacek@redhat.com>
70         PR c++/113987
71         * call.cc (conv_binds_to_reference_parm_p): New.
72         * cp-tree.h (conv_binds_to_reference_parm_p): Declare.
73         * init.cc (find_uninit_fields_r): Call it.
75 2024-02-29  Nathaniel Shead  <nathanieloshead@gmail.com>
77         PR c++/111710
78         * cp-tree.h (DECL_MODULE_KEYED_DECLS_P): Remove tree checking.
79         (struct lang_decl_base): Update comments and fix whitespace.
80         * module.cc (trees_out::lang_decl_bools): Always write
81         module_keyed_decls_p flag...
82         (trees_in::lang_decl_bools): ...and always read it.
83         (trees_out::decl_value): Handle all kinds of keyed decls.
84         (trees_in::decl_value): Likewise.
85         (trees_in::tree_value): Deduplicate LAMBDA_EXPRs.
86         (maybe_key_decl): Also support lambdas attached to fields,
87         parameters, and types. Key lambdas attached to fields to their
88         class.
89         (trees_out::get_merge_kind): Likewise.
90         (trees_out::key_mergeable): Likewise.
91         (trees_in::key_mergeable): Support keyed decls in a TYPE_DECL
92         container.
93         * parser.cc (cp_parser_class_head): Start a lambda scope when
94         parsing base classes.
96 2024-02-28  Jakub Jelinek  <jakub@redhat.com>
97             Patrick Palka  <ppalka@redhat.com>
99         PR c++/113976
100         * decl.cc (grokdeclarator): Don't call cp_apply_type_quals_to_decl
101         on DECL_TEMPLATE_INSTANTIATED VAR_DECLs.
103 2024-02-28  Nathaniel Shead  <nathanieloshead@gmail.com>
105         PR c++/113970
106         PR c++/114013
107         * decl.cc (make_rtl_for_nonlocal_decl): Don't defer inline
108         variables.
110 2024-02-23  Jakub Jelinek  <jakub@redhat.com>
112         PR c++/113083
113         * cp-gimplify.cc (cp_fold): For targetm.cxx.cdtor_returns_this ()
114         wrap r into a COMPOUND_EXPR and return folded CALL_EXPR_ARG (x, 0).
116 2024-02-19  Patrick Palka  <ppalka@redhat.com>
118         PR c++/113966
119         * constraint.cc (tsubst_compound_requirement): Don't check
120         the noexcept condition or the return-type-requirement when
121         partially substituting.
123 2024-02-17  Marek Polacek  <polacek@redhat.com>
125         PR c++/113158
126         * search.cc (maybe_check_overriding_exception_spec): Defer checking
127         when a noexcept couldn't be instantiated & evaluated to false/true.
129 2024-02-16  Marek Polacek  <polacek@redhat.com>
131         DR 1351
132         * search.cc (maybe_check_overriding_exception_spec): Don't error about
133         a looser exception specification if the overrider is deleted.
135 2024-02-16  Marek Polacek  <polacek@redhat.com>
137         PR c++/113789
138         PR c++/113853
139         * typeck.cc (treat_lvalue_as_rvalue_p): Update code to better
140         reflect [expr.prim.id.unqual]#4.2.
142 2024-02-16  Jakub Jelinek  <jakub@redhat.com>
144         PR c++/113929
145         * parser.cc (cp_parser_parameter_declaration): Diagnose this specifier
146         on template parameter declaration.
148 2024-02-16  Patrick Palka  <ppalka@redhat.com>
150         * module.cc (trees_out::core_bools): Stream TREE_UNAVAILABLE.
151         (trees_in::core_bools): Likewise.
152         (trees_out::core_vals): Stream LAMBDA_EXPR_REGEN_INFO.
153         (trees_in::core_vals): Likewise.
155 2024-02-14  Nathaniel Shead  <nathanieloshead@gmail.com>
157         PR c++/113708
158         * decl.cc (make_rtl_for_nonlocal_decl): Defer inline variables.
159         * decl2.cc (import_export_decl): Support inline variables.
161 2024-02-14  Patrick Palka  <ppalka@redhat.com>
163         PR c++/113908
164         PR c++/113332
165         * method.cc (synthesized_method_walk): Use maybe_push_to_top_level.
167 2024-02-14  Nathaniel Shead  <nathanieloshead@gmail.com>
169         PR c++/99573
170         * decl.cc (start_enum): Reorder check for redeclaring in module.
171         Add missing auto_diagnostic_groups.
173 2024-02-13  Marek Polacek  <polacek@redhat.com>
175         DR 1693
176         PR c++/113760
177         * parser.cc (cp_parser_member_declaration): Only pedwarn about an extra
178         semicolon in C++98.
180 2024-02-13  Tobias Burnus  <tburnus@baylibre.com>
182         PR middle-end/113904
183         * parser.cc (cp_parser_omp_context_selector): Handle splitting of
184         OMP_TRAIT_PROPERTY_EXPR into OMP_TRAIT_PROPERTY_{DEV_NUM,BOOL}_EXPR.
186 2024-02-13  Patrick Palka  <ppalka@redhat.com>
188         * Make-lang.in (CFLAGS-cp/module.o): Add $(ZLIBINC).
189         * module.cc: Include <zlib.h>.
190         (bytes::calc_crc): Use crc32 from zlib.
191         (bytes_out::set_crc): Use crc32_combine from zlib.
193 2024-02-13  Patrick Palka  <ppalka@redhat.com>
195         * module.cc (depset::hash::add_specializations): Use
196         STRIP_TEMPLATE consistently.
197         (get_originating_module_decl): Handle class-scope CONST_DECL.
199 2024-02-13  Patrick Palka  <ppalka@redhat.com>
201         * lambda.cc (lambda_function): Call get_class_binding_direct
202         instead of lookup_member to sidestep lazy loading.
203         * name-lookup.cc (check_local_shadow): Punt if we're in a
204         function context that's not actual parsing.
206 2024-02-13  Jason Merrill  <jason@redhat.com>
208         PR c++/113612
209         * pt.cc (process_partial_specialization): Return early
210         on redeclaration.
212 2024-02-13  Marek Polacek  <polacek@redhat.com>
214         PR c++/112436
215         * except.cc (expand_start_catch_block): Pass tf_warning_or_error to
216         is_admissible_throw_operand_or_catch_parameter.
217         (build_throw): Pass complain to
218         is_admissible_throw_operand_or_catch_parameter.
219         (complete_ptr_ref_or_void_ptr_p): Add a tsubst_flags_t parameter.  Use
220         it.  Return bool.  Call complete_type_or_maybe_complain instead of
221         complete_type_or_else.
222         (is_admissible_throw_operand_or_catch_parameter): Add a tsubst_flags_t
223         parameter.  Use it.  Guard error calls.
225 2024-02-13  Alex Coplan  <alex.coplan@arm.com>
227         PR c++/113658
228         * cp-objcp-common.cc (cp_feature_table): Remove entry for
229         cxx_constexpr_string_builtins.
231 2024-02-12  Marek Polacek  <polacek@redhat.com>
233         PR c++/113545
234         * constexpr.cc (cxx_eval_switch_expr): If the condition doesn't reduce
235         to an INTEGER_CST, consider it non-constant.
237 2024-02-10  Marek Polacek  <polacek@redhat.com>
239         DR 2237
240         PR c++/107126
241         PR c++/97202
242         * parser.cc (cp_parser_unqualified_id): Downgrade the DR2237 error to
243         a pedwarn.
244         (cp_parser_constructor_declarator_p): Likewise.
246 2024-02-10  Jakub Jelinek  <jakub@redhat.com>
248         * tree.cc (debug_binfo): Use HOST_WIDE_INT_PRINT_DEC instead of "%ld"
249         and casts to long.
250         * pt.cc (print_template_statistics): Use HOST_SIZE_T_PRINT_DEC
251         and casts to fmt_size_t instead of "%ld" and casts to long.
252         * class.cc (dump_class_hierarchy_1): Use HOST_WIDE_INT_PRINT_UNSIGNED
253         instead of "%lu" and casts to unsigned long.  For TYPE_ALIGN, use
254         %u instead of %lu and drop casts to unsigned long.
255         * parser.cc (cp_lexer_peek_nth_token): Use HOST_SIZE_T_PRINT_DEC
256         and casts to fmt_size_t instead of "%ld" and casts to long.
258 2024-02-09  Marek Polacek  <polacek@redhat.com>
260         PR c++/113834
261         * semantics.cc (finish_type_pack_element): Perform range checking
262         before tree_to_shwi.
264 2024-02-09  Marek Polacek  <polacek@redhat.com>
266         PR c++/98388
267         * coroutines.cc (coro_rewrite_function_body): Pass tf_warning_or_error
268         to build_throw.
269         (morph_fn_to_coro): Likewise.
270         * cp-tree.h (build_throw): Adjust.
271         * except.cc (expand_end_catch_block): Pass tf_warning_or_error to
272         build_throw.
273         (build_throw): Add a tsubst_flags_t parameter.  Use it.  Remove
274         redundant variable.  Guard an inform call.
275         * parser.cc (cp_parser_throw_expression): Pass tf_warning_or_error
276         to build_throw.
277         * pt.cc (tsubst_expr) <case THROW_EXPR>: Pass complain to build_throw.
279 2024-02-09  Patrick Palka  <ppalka@redhat.com>
281         PR c++/112580
282         * module.cc (trees_in::read_class_def): When streaming in
283         an anonymous union field of an as-base class, don't overwrite
284         ANON_AGGR_TYPE_FIELD.
286 2024-02-08  Patrick Palka  <ppalka@redhat.com>
288         PR c++/113649
289         * pt.cc (do_class_deduction): Add outer_targs parameter.
290         Substitute outer arguments into the CTAD template.
291         (do_auto_deduction): Pass outer_targs to do_class_deduction.
293 2024-02-08  Jason Merrill  <jason@redhat.com>
295         * pt.cc (create_template_parm_object): Pass TARGET_EXPR to
296         cxx_constant_value.
298 2024-02-06  Jakub Jelinek  <jakub@redhat.com>
300         PR c++/113788
301         * parser.cc (CP_PARSER_FLAGS_PARAMETER): New enumerator.
302         (cp_parser_decl_specifier_seq): Parse RID_THIS only if
303         CP_PARSER_FLAGS_PARAMETER is set in flags.
304         (cp_parser_parameter_declaration): Or in CP_PARSER_FLAGS_PARAMETER
305         when calling cp_parser_decl_specifier_seq.
307 2024-02-06  Marek Polacek  <polacek@redhat.com>
309         * method.cc (early_check_defaulted_comparison): Add
310         auto_diagnostic_group.
312 2024-02-06  Jason Merrill  <jason@redhat.com>
314         PR c++/107291
315         * method.cc (early_check_defaulted_comparison): Fail if not friend.
317 2024-02-05  Jason Merrill  <jason@redhat.com>
319         PR c++/111286
320         * tree.cc (rvalue): Don't drop cv-quals from an array.
322 2024-02-03  Patrick Palka  <ppalka@redhat.com>
324         PR c++/110006
325         PR c++/112769
326         * constraint.cc (subst_info::quiet): Accomodate non-diagnostic
327         tsubst flags.
328         (tsubst_valid_expression_requirement): Likewise.
329         (tsubst_simple_requirement): Return a substituted _REQ node when
330         processing_template_decl.
331         (tsubst_type_requirement_1): Accomodate non-diagnostic tsubst
332         flags.
333         (tsubst_type_requirement): Return a substituted _REQ node when
334         processing_template_decl.
335         (tsubst_compound_requirement): Likewise.  Accomodate non-diagnostic
336         tsubst flags.
337         (tsubst_nested_requirement): Likewise.
338         (tsubst_requires_expr): Don't defer partial substitution when
339         processing_constraint_expression_p is true, in which case return
340         a substituted REQUIRES_EXPR.
341         * pt.cc (tsubst_expr) <case REQUIRES_EXPR>: Accomodate
342         non-diagnostic tsubst flags.
344 2024-02-02  Jason Merrill  <jason@redhat.com>
346         PR c++/110084
347         * pt.cc (tsubst_function_decl): Only check a function defaulted
348         outside the class if the class is complete.
350 2024-02-02  Jason Merrill  <jason@redhat.com>
352         PR c++/112439
353         * constexpr.cc (cxx_eval_store_expression): Check empty_base
354         before marking a CONSTRUCTOR readonly.
356 2024-02-02  Jason Merrill  <jason@redhat.com>
358         PR c++/113638
359         * cp-tree.h: Adjust comment.
360         * pt.cc (instantiate_template): Set VAR_HAD_UNKNOWN_BOUND for
361         variable template.
363 2024-02-01  Marek Polacek  <polacek@redhat.com>
365         * call.cc (reference_like_class_p): Consider even non-templates for
366         std::span-like classes.
368 2024-02-01  Patrick Palka  <ppalka@redhat.com>
370         PR c++/112737
371         * pt.cc (iterative_hash_template_arg) <case TEMPLATE_DECL>:
372         Adjust hashing to match cp_tree_equal.
373         (ctp_hasher::hash): Also hash CLASS_PLACEHOLDER_TEMPLATE.
374         * tree.cc (cp_tree_equal) <case TEMPLATE_DECL>: Return true
375         for ttp TEMPLATE_DECLs if their TEMPLATE_TEMPLATE_PARMs are
376         equivalent.
377         * typeck.cc (structural_comptypes) <case TEMPLATE_TYPE_PARM>:
378         Use cp_tree_equal to compare CLASS_PLACEHOLDER_TEMPLATE.
380 2024-02-01  Marek Polacek  <polacek@redhat.com>
382         PR c++/112437
383         * typeck.cc (treat_lvalue_as_rvalue_p): Bail out on sk_namespace in
384         the move on throw of parms loop.
386 2024-01-30  Marek Polacek  <polacek@redhat.com>
388         PR c++/110358
389         PR c++/109640
390         * call.cc (reference_like_class_p): Don't warn for std::span-like
391         classes.
393 2024-01-30  Patrick Palka  <ppalka@redhat.com>
395         PR c++/113640
396         * call.cc (keep_unused_object_arg): Punt for an xobj member
397         function.
399 2024-01-30  Patrick Palka  <ppalka@redhat.com>
401         PR c++/113644
402         * pt.cc (unify) <case INTEGER_CST>: Handle NULL_TREE type.
404 2024-01-30  Nathaniel Shead  <nathanieloshead@gmail.com>
406         PR c++/107594
407         * module.cc (get_module): Bail on empty name.
409 2024-01-29  Jason Merrill  <jason@redhat.com>
411         PR c++/113544
412         * pt.cc (instantiate_class_template): Don't partially instantiate.
413         (tsubst_stmt): Likewise.
415 2024-01-26  Nathaniel Shead  <nathanieloshead@gmail.com>
417         PR c++/113580
418         * module.cc (struct post_process_data): Create.
419         (trees_in::post_decls): Use.
420         (trees_in::post_process): Return entire vector at once.
421         Change overload to take post_process_data instead of tree.
422         (trees_out::write_function_def): Write needed flags from
423         DECL_STRUCT_FUNCTION.
424         (trees_in::read_function_def): Read them and pass to
425         post_process.
426         (module_state::read_cluster): Write flags into cfun.
428 2024-01-26  Nathaniel Shead  <nathanieloshead@gmail.com>
430         PR c++/112899
431         * cp-tree.h (note_variable_template_instantiation): Rename to...
432         (note_vague_linkage_variable): ...this.
433         * decl2.cc (note_variable_template_instantiation): Rename to...
434         (note_vague_linkage_variable): ...this.
435         * pt.cc (instantiate_decl): Rename usage of above function.
436         * module.cc (trees_in::read_var_def): Remember pending statics
437         that we stream in.
439 2024-01-25  Jakub Jelinek  <jakub@redhat.com>
441         PR c++/113599
442         * typeck2.cc (build_m_component_ref): Use convert instead of
443         cp_convert for pointer conversion.
445 2024-01-25  Jason Merrill  <jason@redhat.com>
447         PR c++/113598
448         * init.cc (build_vec_init): Don't use {} for PMF.
450 2024-01-25  Jason Merrill  <jason@redhat.com>
452         PR c++/109227
453         * coroutines.cc (build_co_await): Use cxx_maybe_build_cleanup.
454         (build_actor_fn, process_conditional, maybe_promote_temps)
455         (morph_fn_to_coro): Likewise.
456         (expand_one_await_expression): Use build_cleanup.
458 2024-01-25  Nathaniel Shead  <nathanieloshead@gmail.com>
460         PR c++/113405
461         * module.cc (set_defining_module): Track partial specialisations
462         for all declarations.
464 2024-01-25  Nathaniel Shead  <nathanieloshead@gmail.com>
466         PR c++/100707
467         * name-lookup.cc (add_imported_namespace): Don't mark namespaces
468         as imported.
470 2024-01-24  Patrick Palka  <ppalka@redhat.com>
472         PR c++/113529
473         * call.cc (add_operator_candidates): Propagate error_mark_node
474         result after recursing to find rewritten candidates.
476 2024-01-23  Marek Polacek  <polacek@redhat.com>
478         PR c++/113256
479         PR c++/111607
480         PR c++/109640
481         * call.cc (do_warn_dangling_reference): Don't warn if the temporary
482         is of lambda type.
484 2024-01-23  Nathaniel Shead  <nathanieloshead@gmail.com>
486         PR c++/112820
487         PR c++/102607
488         * module.cc (trees_out::lang_type_bools): Write interface_only
489         and interface_unknown.
490         (trees_in::lang_type_bools): Read the above flags.
491         (trees_in::decl_value): Reset CLASSTYPE_INTERFACE_* except for
492         extern templates.
493         (trees_in::read_class_def): Remove buggy extern template
494         handling.
496 2024-01-19  Jason Merrill  <jason@redhat.com>
498         PR c++/113498
499         * pt.cc (decl_template_info): New fn.
500         (get_template_info): Use it.
502 2024-01-19  Jason Merrill  <jason@redhat.com>
504         PR c++/112632
505         PR c++/112594
506         PR c++/111357
507         PR c++/104594
508         PR c++/67898
509         * cp-tree.h (IMPLICIT_CONV_EXPR_FORCED): New.
510         * pt.cc (expand_integer_pack): Remove 111357 workaround.
511         (maybe_convert_nontype_argument): Add force parm.
512         (convert_template_argument): Handle alias template args
513         specially.
514         (tsubst_expr): Don't ignore IMPLICIT_CONV_EXPR_NONTYPE_ARG.
515         * error.cc (dump_expr) [CASE_CONVERT]: Handle null optype.
517 2024-01-18  Marek Polacek  <polacek@redhat.com>
519         PR c++/113389
520         * decl.cc (grokdeclarator) <case cdk_function>: Set TREE_PURPOSE to
521         NULL_TREE when emitting an error.
523 2024-01-17  Nathaniel Shead  <nathanieloshead@gmail.com>
525         PR c++/112588
526         * module.cc (trees_in::read_function_def): Don't overwrite
527         arguments.
529 2024-01-17  Patrick Palka  <ppalka@redhat.com>
531         PR c++/113242
532         PR c++/99493
533         * pt.cc (invalid_tparm_referent_p) <case ADDR_EXPR>: Suppress
534         DECL_ARTIFICIAL rejection test for class NTTP objects.
536 2024-01-16  Nathaniel Shead  <nathanieloshead@gmail.com>
538         PR c++/113292
539         * decl2.cc (get_tls_wrapper_fn): Set DECL_CONTEXT.
540         (c_parse_final_cleanups): Suppress warning for no definition of
541         TLS wrapper functions in header modules.
542         * module.cc (trees_out::lang_decl_vals): Write wrapped variable
543         for TLS wrapper functions.
544         (trees_in::lang_decl_vals): Read it.
545         (trees_out::decl_value): Write TLS model for thread-local vars.
546         (trees_in::decl_value): Read it for new decls. Remember to emit
547         definitions of TLS wrapper functions later.
549 2024-01-16  Nathaniel Shead  <nathanieloshead@gmail.com>
551         * name-lookup.h (enum scope_kind): Add 'sk_count'.
552         * name-lookup.cc (cp_binding_level_descriptor): Add missing
553         scope kinds. Add assertion that the list is up to date. Fix
554         handling of explicit_spec_p.
556 2024-01-16  Marek Polacek  <polacek@redhat.com>
558         * decl.cc (grokdeclarator) <case cdk_function>: Tweak diagnostic
559         messages.
561 2024-01-16  Marek Polacek  <polacek@redhat.com>
563         PR c++/113340
564         * decl.cc (grokdeclarator) <case cdk_function>: Clear
565         is_xobj_member_function in case of an error.
567 2024-01-16  waffl3x  <waffl3x@protonmail.com>
569         PR c++/113307
570         * parser.cc (cp_parser_parameter_declaration): Reject packs
571         on xobj params.
573 2024-01-15  Marek Polacek  <polacek@redhat.com>
575         PR c++/110065
576         * parser.cc (cp_parser_template_type_arg): Add auto checking.
578 2024-01-15  Patrick Palka  <ppalka@redhat.com>
580         * parser.cc (cp_parser_check_access_in_redeclaration): Don't
581         check access for a partial or explicit specialization.
582         * pt.cc (maybe_new_partial_specialization): Don't set TREE_PRIVATE
583         or TREE_PROTECTED on the newly created partial specialization.
585 2024-01-15  Patrick Palka  <ppalka@redhat.com>
587         PR c++/104634
588         * pt.cc (maybe_new_partial_specialization): Propagate TREE_PUBLIC
589         to the newly created partial specialization.
591 2024-01-15  Patrick Palka  <ppalka@redhat.com>
593         PR c++/109899
594         * init.cc (build_vec_delete_1): Assume expr_noexcept_p returns
595         false in a template context.
597 2024-01-13  Jakub Jelinek  <jakub@redhat.com>
599         * mangle.cc (write_nested_name): Mangle explicit object
600         member functions with H as per
601         https://github.com/itanium-cxx-abi/cxx-abi/issues/148 non-proposal.
603 2024-01-12  Jason Merrill  <jason@redhat.com>
605         PR c++/113038
606         * name-lookup.cc (lookup_elaborated_type): Look for bindings
607         in the global namespace in the ABI namespace.
609 2024-01-12  Jason Merrill  <jason@redhat.com>
611         * call.cc (reversed_match): New.
612         (enum class pmatch): New enum.
613         (cand_parms_match): Add match_kind parm.
614         (object_parms_correspond): Add fn parms.
615         (joust): Adjust.
616         * class.cc (xobj_iobj_parameters_correspond): Rename to...
617         (iobj_parm_corresponds_to): ...this.  Take the other
618         type instead of a second function.
619         (object_parms_correspond): Adjust.
620         * cp-tree.h (iobj_parm_corresponds_to): Declare.
622 2024-01-11  Jason Merrill  <jason@redhat.com>
624         PR c++/113191
625         * class.cc (xobj_iobj_parameters_correspond): Add context parm.
626         (object_parms_correspond): Factor out of...
627         (add_method): ...here.
628         * method.cc (defaulted_late_check): Use it.
629         * call.cc (class_of_implicit_object): New.
630         (object_parms_correspond): Overload taking two candidates.
631         (cand_parms_match): Use it.
632         (joust): Check reversed before comparing constraints.
633         * cp-tree.h (object_parms_correspond): Declare.
635 2024-01-10  Tamar Christina  <tamar.christina@arm.com>
637         * parser.cc (cp_parser_pragma): Initialize to false.
639 2024-01-09  Jason Merrill  <jason@redhat.com>
641         * semantics.cc (is_object_parameter): New.
642         * cp-tree.h (is_object_parameter): Declare.
643         * call.cc (maybe_warn_class_memaccess): Use it.
644         * search.cc (field_access_p): Use it.
645         (class_of_object_parm): New.
646         (field_accessor_p): Adjust for explicit object parms.
648 2024-01-09  Jason Merrill  <jason@redhat.com>
650         * call.cc (build_over_call): Refactor handle_arg lambda.
651         * class.cc (xobj_iobj_parameters_correspond): Fix FIXME.
652         * method.cc (defaulted_late_check): Adjust comments.
654 2024-01-09  waffl3x  <waffl3x@protonmail.com>
656         PR c++/102609
657         PR c++/102609
658         C++23 P0847R7 (deducing this) - CWG2586.
659         * decl.cc (copy_fn_p): Accept xobj copy assignment functions.
660         (move_signature_fn_p): Accept xobj move assignment functions.
661         * method.cc (do_build_copy_assign): Handle defaulted xobj member
662         functions.
663         (defaulted_late_check): Comment.
664         (defaultable_fn_check): Comment.
666 2024-01-09  waffl3x  <waffl3x@protonmail.com>
668         PR c++/102609
669         PR c++/102609
670         C++23 P0847R7 (deducing this) - xobj lambdas.
671         * lambda.cc (build_capture_proxy): Don't fold direct object types.
672         * parser.cc (cp_parser_lambda_declarator_opt): Handle xobj lambdas,
673         diagnostics.  Comments also updated.
674         * pt.cc (tsubst_function_decl): Handle xobj lambdas.  Check object
675         type of xobj lambda call operator, diagnose incorrect types.
676         (tsubst_lambda_expr): Update comment.
677         * semantics.cc (finish_decltype_type): Also consider by-value object
678         parameter qualifications.
680 2024-01-09  waffl3x  <waffl3x@protonmail.com>
682         PR c++/102609
683         PR c++/102609
684         C++23 P0847R7 (deducing this) - diagnostics.
685         * class.cc (resolve_address_of_overloaded_function): Diagnostics.
686         * cp-tree.h (TFF_XOBJ_FUNC): Define.
687         * decl.cc (grokfndecl): Diagnostics.
688         (grokdeclarator): Diagnostics.
689         * error.cc (dump_aggr_type): Pass TFF_XOBJ_FUNC.
690         (dump_lambda_function): Formatting for xobj lambda.
691         (dump_function_decl): Pass TFF_XOBJ_FUNC.
692         (dump_parameters): Formatting for xobj member functions.
693         (function_category): Formatting for xobj member functions.
694         * parser.cc (cp_parser_decl_specifier_seq): Diagnostics.
695         (cp_parser_parameter_declaration): Diagnostics.
696         * search.cc (look_for_overrides_here): Make xobj member functions
697         override.
698         (look_for_overrides_r): Reject an overriding xobj member function
699         and diagnose it.
700         * semantics.cc (finish_this_expr): Diagnostics.
701         * typeck.cc (cp_build_addr_expr_1): Diagnostics.
703 2024-01-09  waffl3x  <waffl3x@protonmail.com>
705         PR c++/102609
706         PR c++/102609
707         C++23 P0847R7 (deducing this) - initial functionality.
708         * class.cc (xobj_iobj_parameters_correspond): New function, checks
709         for corresponding object parameters between xobj and iobj member
710         functions.
711         (add_method): Handle object parameters of xobj member functions, use
712         xobj_iobj_parameters_correspond.
713         * call.cc (build_over_call): Refactor, handle xobj member functions.
714         (cand_parms_match): Handle object parameters of xobj and iobj member
715         functions, use xobj_iobj_parameters_correspond.
716         * cp-tree.h (enum cp_decl_spec): Add ds_this, add comments.
717         * decl.cc (grokfndecl): Add xobj_func_p parameter.  For xobj member
718         functions, Set xobj_flag, don't set static_function flag.
719         (grokdeclarator): Handle xobj member functions, tell grokfndecl.
720         (grok_op_properties): Don't error for xobj operators.
721         * parser.cc (cp_parser_decl_specifier_seq): Handle this specifier.
722         (cp_parser_parameter_declaration): Set default argument to
723         "this_identifier" for xobj parameters.
724         (set_and_check_decl_spec_loc): Add "this", add comments.
725         * tree.cc (build_min_non_dep_op_overload): Handle xobj operators.
726         * typeck.cc (cp_build_addr_expr_1): Handle address-of xobj member
727         functions.
729 2024-01-09  waffl3x  <waffl3x@protonmail.com>
730             Jason Merrill  <jason@redhat.com>
732         PR c++/102609
733         * cp-tree.h (struct lang_decl_fn): New data member.
734         (DECL_NONSTATIC_MEMBER_FUNCTION_P): Poison.
735         (DECL_IOBJ_MEMBER_FUNCTION_P): Define.
736         (DECL_FUNCTION_XOBJ_FLAG): Define.
737         (DECL_XOBJ_MEMBER_FUNCTION_P): Define.
738         (DECL_OBJECT_MEMBER_FUNCTION_P): Define.
739         (DECL_FUNCTION_MEMBER_P): Don't use
740         DECL_NONSTATIC_MEMBER_FUNCTION_P.
741         (DECL_CONST_MEMFUNC_P): Likewise.
742         (DECL_VOLATILE_MEMFUNC_P): Likewise.
743         (DECL_NONSTATIC_MEMBER_P): Likewise.
744         * module.cc (trees_out::lang_decl_bools): Handle xobj_flag.
745         (trees_in::lang_decl_bools): Handle xobj_flag.
746         * call.cc (build_this_conversion)
747         (add_function_candidate)
748         (add_template_candidate_real)
749         (add_candidates)
750         (maybe_warn_class_memaccess)
751         (cand_parms_match)
752         (joust)
753         (do_warn_dangling_reference)
754         * class.cc (finalize_literal_type_property)
755         (finish_struct)
756         (resolve_address_of_overloaded_function)
757         * constexpr.cc (is_valid_constexpr_fn)
758         (cxx_bind_parameters_in_call)
759         * contracts.cc (build_contract_condition_function)
760         * cp-objcp-common.cc (cp_decl_dwarf_attribute)
761         * cxx-pretty-print.cc (cxx_pretty_printer::postfix_expression)
762         (cxx_pretty_printer::declaration_specifiers)
763         (cxx_pretty_printer::direct_declarator)
764         * decl.cc (cp_finish_decl)
765         (grok_special_member_properties)
766         (start_preparsed_function)
767         (record_key_method_defined)
768         * decl2.cc (cp_handle_deprecated_or_unavailable)
769         * init.cc (find_uninit_fields_r)
770         (build_offset_ref)
771         * lambda.cc (lambda_expr_this_capture)
772         (maybe_generic_this_capture)
773         (nonlambda_method_basetype)
774         * mangle.cc (write_nested_name)
775         * method.cc (early_check_defaulted_comparison)
776         (skip_artificial_parms_for)
777         (num_artificial_parms_for)
778         * pt.cc (is_specialization_of_friend)
779         (determine_specialization)
780         (copy_default_args_to_explicit_spec)
781         (check_explicit_specialization)
782         (tsubst_contract_attribute)
783         (check_non_deducible_conversions)
784         (more_specialized_fn)
785         (maybe_instantiate_noexcept)
786         (register_parameter_specializations)
787         (value_dependent_expression_p)
788         * search.cc (shared_member_p)
789         (lookup_member)
790         (field_access_p)
791         * semantics.cc (finish_omp_declare_simd_methods)
792         * tree.cc (lvalue_kind)
793         * typeck.cc (invalid_nonstatic_memfn_p): Don't use
794         DECL_NONSTATIC_MEMBER_FUNCTION_P.
796 2024-01-09  Julian Brown  <julian@codesourcery.com>
798         * constexpr.cc (potential_consant_expression_1): Handle
799         OMP_ARRAY_SECTION.
800         * cp-tree.h (grok_omp_array_section, build_omp_array_section): Add
801         prototypes.
802         * decl2.cc (grok_omp_array_section): New function.
803         * error.cc (dump_expr): Handle OMP_ARRAY_SECTION.
804         * parser.cc (cp_parser_new): Initialize parser->omp_array_section_p.
805         (cp_parser_statement_expr): Disallow array sections.
806         (cp_parser_postfix_open_square_expression): Support OMP_ARRAY_SECTION
807         parsing.
808         (cp_parser_parenthesized_expression_list, cp_parser_lambda_expression,
809         cp_parser_braced_list): Disallow array sections.
810         (cp_parser_omp_var_list_no_open): Remove ALLOW_DEREF parameter, add
811         MAP_LVALUE in its place.  Support generalised lvalue parsing for
812         OpenMP map, to and from clauses.  Use OMP_ARRAY_SECTION
813         code instead of TREE_LIST to represent OpenMP array sections.
814         (cp_parser_omp_var_list): Remove ALLOW_DEREF parameter, add MAP_LVALUE.
815         Pass to cp_parser_omp_var_list_no_open.
816         (cp_parser_oacc_data_clause): Update call to cp_parser_omp_var_list.
817         (cp_parser_omp_clause_map): Add sk_omp scope around
818         cp_parser_omp_var_list_no_open call.
819         * parser.h (cp_parser): Add omp_array_section_p field.
820         * pt.cc (tsubst, tsubst_copy, tsubst_omp_clause_decl,
821         tsubst_copy_and_build): Add OMP_ARRAY_SECTION support.
822         * semantics.cc (handle_omp_array_sections_1, handle_omp_array_sections,
823         cp_oacc_check_attachments, finish_omp_clauses): Use OMP_ARRAY_SECTION
824         instead of TREE_LIST where appropriate.  Handle more types of map
825         expression.
826         * typeck.cc (build_omp_array_section): New function.
828 2024-01-07  Nathaniel Shead  <nathanieloshead@gmail.com>
830         * module.cc (trees_out::write_var_def): Only write initializers
831         in header modules.
833 2024-01-07  Nathaniel Shead  <nathanieloshead@gmail.com>
835         PR c++/109679
836         * module.cc (depset::hash::add_binding_entity): Don't skip names
837         in the GMF if they've been exported with a using declaration.
839 2024-01-07  Nathaniel Shead  <nathanieloshead@gmail.com>
841         PR c++/110808
842         * parser.cc (cp_parser_module_name): Rewrite to handle
843         module-names and module-partitions independently.
844         (cp_parser_module_partition): New function.
845         (cp_parser_module_declaration): Parse module partitions
846         explicitly. Don't change state if parsing module decl failed.
847         (cp_parser_import_declaration): Handle different kinds of
848         import-declarations locally.
850 2024-01-03  Patrick Palka  <ppalka@redhat.com>
852         PR c++/113064
853         * call.cc (reference_binding): Still try a conversion via a
854         temporary if a direct conversion was bad.
856 2024-01-03  Kwok Cheung Yeung  <kcy@codesourcery.com>
858         * parser.cc (cp_parser_omp_clause_name): Move handling of indirect
859         clause to correspond to alphabetical order.
862 Copyright (C) 2024 Free Software Foundation, Inc.
864 Copying and distribution of this file, with or without modification,
865 are permitted in any medium without royalty provided the copyright
866 notice and this notice are preserved.