]>
Commit | Line | Data |
---|---|---|
0faf3a1e GA |
1 | 2022-04-29 Iain Sandoe <iain@sandoe.co.uk> |
2 | ||
3 | Backported from master: | |
4 | 2022-04-29 Iain Sandoe <iain@sandoe.co.uk> | |
5 | ||
6 | PR c++/105426 | |
7 | * coroutines.cc (register_local_var_uses): Allow promotion of unnamed | |
8 | temporaries to coroutine frame copies. | |
9 | ||
ab73f5b0 GA |
10 | 2022-04-28 Patrick Palka <ppalka@redhat.com> |
11 | ||
12 | Backported from master: | |
13 | 2022-04-28 Patrick Palka <ppalka@redhat.com> | |
14 | ||
15 | PR c++/105425 | |
16 | * pt.cc (unify) <case TEMPLATE_PARM_INDEX>: Treat | |
17 | DEPENDENT_OPERATOR_TYPE like an empty type. | |
18 | ||
19 | 2022-04-28 Iain Sandoe <iain@sandoe.co.uk> | |
20 | ||
21 | PR c++/104051 | |
22 | * coroutines.cc (coro_diagnose_throwing_final_aw_expr): Handle | |
23 | non-target expression inputs. | |
24 | ||
25 | 2022-04-28 Iain Sandoe <iain@sandoe.co.uk> | |
26 | ||
27 | PR c++/105301 | |
28 | * coroutines.cc (coro_promise_type_found_p): Account for possible | |
29 | mutliple overloads of the promise return_value() method. | |
30 | ||
31 | 2022-04-28 Iain Sandoe <iain@sandoe.co.uk> | |
32 | ||
33 | PR c++/105287 | |
34 | * coroutines.cc (maybe_promote_temps): Ensure generated temporaries | |
35 | are added to the bind expr. | |
36 | (add_var_to_bind): Fix local var naming to use portable punctuation. | |
37 | (register_local_var_uses): Do not add synthetic names to unnamed | |
38 | temporaries. | |
39 | ||
40 | 2022-04-28 Nathan Sidwell <nathan@acm.org> | |
41 | Iain Sandoe <iain@sandoe.co.uk> | |
42 | ||
43 | PR c++/103868 | |
44 | * coroutines.cc (finish_co_await_expr): Do not process non-dependent | |
45 | coroutine expressions at template definition time. | |
46 | (finish_co_yield_expr): Likewise. | |
47 | (finish_co_return_stmt): Likewise. | |
48 | ||
49 | 2022-04-28 Marek Polacek <polacek@redhat.com> | |
50 | ||
51 | PR c++/90107 | |
52 | * parser.cc (cp_parser_class_specifier_1): Accept :: after a class | |
53 | definition. | |
54 | ||
ba949a6a GA |
55 | 2022-04-27 Jason Merrill <jason@redhat.com> |
56 | ||
57 | * tree.cc (strip_typedefs): Add default argument comments. | |
58 | ||
59 | 2022-04-27 Marek Polacek <polacek@redhat.com> | |
60 | ||
61 | PR c++/105398 | |
62 | * pt.cc (uses_template_parms): Return false for any NAMESPACE_DECL. | |
63 | ||
01ad093b GA |
64 | 2022-04-26 Jason Merrill <jason@redhat.com> |
65 | ||
66 | PR c++/102629 | |
67 | * pt.cc (gen_elem_of_pack_expansion_instantiation): Clear | |
68 | TEMPLATE_TYPE_PARAMETER_PACK on auto. | |
69 | ||
70 | 2022-04-26 Patrick Palka <ppalka@redhat.com> | |
71 | ||
72 | PR c++/105386 | |
73 | * semantics.cc (finish_decltype_type): Pass tf_decltype to | |
74 | instantiate_non_dependent_expr_sfinae. | |
75 | ||
76 | 2022-04-26 Jason Merrill <jason@redhat.com> | |
77 | ||
78 | PR c++/104624 | |
79 | * pt.cc (check_for_bare_parameter_packs): Check for lambda | |
80 | function parameter pack. | |
81 | ||
82 | 2022-04-26 Patrick Palka <ppalka@redhat.com> | |
83 | ||
84 | PR c++/105289 | |
85 | PR c++/86193 | |
86 | * pt.cc (process_partial_specialization): Downgrade "partial | |
87 | specialization isn't more specialized" diagnostic from permerror | |
88 | to an on-by-default pedwarn. | |
89 | (unify) <case TEMPLATE_PARM_INDEX>: When substituting into the | |
90 | NTTP type a second time, use the original type not the | |
91 | substituted type. | |
92 | ||
98de0da6 GA |
93 | 2022-04-25 Marek Polacek <polacek@redhat.com> |
94 | ||
95 | PR c++/105353 | |
96 | * typeck.cc (build_x_shufflevector): Use | |
97 | instantiation_dependent_expression_p except for the first two | |
98 | arguments. | |
99 | ||
c1a9cf67 GA |
100 | 2022-04-21 Marek Polacek <polacek@redhat.com> |
101 | ||
102 | * constexpr.cc (cxx_eval_logical_expression): Remove unused | |
103 | parameter. | |
104 | (cxx_eval_constant_expression) <case TRUTH_ANDIF_EXPR>, | |
105 | <case TRUTH_OR_EXPR>: Adjust calls to cxx_eval_logical_expression. | |
106 | ||
107 | 2022-04-21 Marek Polacek <polacek@redhat.com> | |
108 | ||
109 | PR c++/105321 | |
110 | * constexpr.cc (cxx_eval_logical_expression): Always pass false for lval | |
111 | to cxx_eval_constant_expression. | |
112 | ||
29a25a60 GA |
113 | 2022-04-20 Ed Catmur <ed@catmur.uk> |
114 | ||
115 | PR c++/104996 | |
116 | * call.cc (compare_ics): When comparing list-initialization | |
117 | sequences, do not return early. | |
118 | ||
d1d57187 GA |
119 | 2022-04-19 Jakub Jelinek <jakub@redhat.com> |
120 | ||
121 | PR c++/105256 | |
122 | * typeck2.cc (process_init_constructor_array, | |
123 | process_init_constructor_record, process_init_constructor_union): Move | |
124 | CONSTRUCTOR_PLACEHOLDER_BOUNDARY flag from CONSTRUCTOR elements to the | |
125 | containing CONSTRUCTOR. | |
126 | ||
587953f0 GA |
127 | 2022-04-15 Marek Polacek <polacek@redhat.com> |
128 | ||
129 | PR c++/105268 | |
130 | * parser.cc (cp_parser_placeholder_type_specifier): Return | |
131 | error_mark_node when trying to build up a constrained parameter in | |
132 | a default argument. | |
133 | ||
134 | 2022-04-15 Jason Merrill <jason@redhat.com> | |
135 | ||
136 | PR c++/102804 | |
137 | * decl.cc (grokdeclarator): Drop typedef used with 'unsigned'. | |
138 | ||
139 | 2022-04-15 Jason Merrill <jason@redhat.com> | |
140 | ||
141 | PR c++/102987 | |
142 | * error.cc (dump_expr): Handle USING_DECL. | |
143 | [VIEW_CONVERT_EXPR]: Just look through location wrapper. | |
144 | ||
031bd52e GA |
145 | 2022-04-14 Jason Merrill <jason@redhat.com> |
146 | ||
147 | PR c++/104646 | |
148 | * constexpr.cc (maybe_save_constexpr_fundef): Don't do extra | |
149 | checks for defaulted ctors. | |
150 | ||
151 | 2022-04-14 Jason Merrill <jason@redhat.com> | |
152 | ||
153 | PR c++/82980 | |
154 | * lambda.cc (type_deducible_expression_p): New. | |
155 | (lambda_capture_field_type): Check it. | |
156 | ||
157 | 2022-04-14 Jason Merrill <jason@redhat.com> | |
158 | ||
159 | PR c++/65211 | |
160 | * pt.cc (tsubst_decl) [TYPE_DECL]: Copy TYPE_ALIGN. | |
161 | ||
162 | 2022-04-14 Jason Merrill <jason@redhat.com> | |
163 | ||
164 | PR c++/97219 | |
165 | * name-lookup.cc (dependent_local_decl_p): New. | |
166 | * cp-tree.h (dependent_local_decl_p): Declare. | |
167 | * semantics.cc (finish_call_expr): Use it. | |
168 | * pt.cc (tsubst_arg_types): Also substitute default args | |
169 | for local externs. | |
170 | ||
171 | 2022-04-14 Jason Merrill <jason@redhat.com> | |
172 | ||
173 | PR c++/101698 | |
174 | * pt.cc (tsubst_baselink): Also check dependent optype. | |
175 | ||
176 | 2022-04-14 Jason Merrill <jason@redhat.com> | |
177 | ||
178 | PR c++/101442 | |
179 | * decl.cc (cp_finish_decl): Don't pass decl to push_cleanup. | |
180 | * init.cc (perform_member_init): Likewise. | |
181 | * semantics.cc (push_cleanup): Adjust comment. | |
182 | ||
247bbed1 GA |
183 | 2022-04-13 Jason Merrill <jason@redhat.com> |
184 | ||
185 | PR c++/105245 | |
186 | PR c++/100111 | |
187 | * constexpr.cc (cxx_eval_store_expression): Build a CONSTRUCTOR | |
188 | as needed in empty base handling. | |
189 | ||
190 | 2022-04-13 Jakub Jelinek <jakub@redhat.com> | |
191 | ||
192 | PR c++/105233 | |
193 | * decl2.cc (cp_check_const_attributes): For aligned attribute | |
194 | pass manifestly_const_eval=true to fold_non_dependent_expr. | |
195 | ||
196 | 2022-04-13 Marek Polacek <polacek@redhat.com> | |
197 | ||
198 | PR c++/97296 | |
199 | * call.cc (direct_reference_binding): strip_top_quals when creating | |
200 | a ck_qual. | |
201 | ||
504dae1d GA |
202 | 2022-04-12 Jason Merrill <jason@redhat.com> |
203 | ||
204 | PR c++/104669 | |
205 | * decl.cc (decls_match): Compare versions even if not recording. | |
206 | (duplicate_decls): Propagate attributes to alias. | |
207 | * decl2.cc (find_last_decl): Give up if versioned. | |
208 | ||
209 | 2022-04-12 Jason Merrill <jason@redhat.com> | |
210 | ||
211 | PR c++/102071 | |
212 | * init.cc (build_new_1): Check array_p for alignment. | |
213 | ||
214 | 2022-04-12 Patrick Palka <ppalka@redhat.com> | |
215 | ||
216 | PR c++/103105 | |
217 | * pt.cc (build_extra_args): Call preserve_args. | |
218 | ||
219 | 2022-04-12 Jason Merrill <jason@redhat.com> | |
220 | ||
221 | PR c++/104142 | |
222 | * decl.cc (check_initializer): Check TREE_SIDE_EFFECTS. | |
223 | ||
224 | 2022-04-12 Jason Merrill <jason@redhat.com> | |
225 | ||
226 | PR c++/105223 | |
227 | PR c++/92918 | |
228 | * class.cc (finish_struct): Always using op=. | |
229 | ||
da066c42 GA |
230 | 2022-04-11 Jason Merrill <jason@redhat.com> |
231 | ||
232 | PR c++/98249 | |
233 | * call.cc (build_operator_new_call): Just look in ::. | |
234 | ||
235 | 2022-04-11 Alexandre Oliva <oliva@adacore.com> | |
236 | ||
237 | * constexpr.cc (cxx_eval_call_expression): Disregard dtor | |
238 | result. | |
239 | ||
240 | 2022-04-11 Alexandre Oliva <oliva@adacore.com> | |
241 | ||
242 | * semantics.cc (set_cleanup_locs): Propagate locus to call | |
243 | wrapped in cast-to-void. | |
244 | ||
245 | 2022-04-11 Jason Merrill <jason@redhat.com> | |
246 | ||
247 | PR c++/100370 | |
248 | * init.cc (warn_placement_new_too_small): Check deref. | |
249 | ||
71cac7de GA |
250 | 2022-04-09 Jason Merrill <jason@redhat.com> |
251 | ||
252 | PR c++/105191 | |
253 | PR c++/92385 | |
254 | * tree.cc (build_vec_init_elt): Do {}-init for aggregates. | |
255 | * constexpr.cc (cxx_eval_vec_init): Only treat {} as value-init | |
256 | for non-aggregate types. | |
257 | (build_vec_init_expr): Also check constancy of explicit | |
258 | initializer elements. | |
259 | ||
260 | 2022-04-09 Jason Merrill <jason@redhat.com> | |
261 | ||
262 | PR c++/91618 | |
263 | PR c++/96604 | |
264 | * name-lookup.cc (set_decl_namespace): Set | |
265 | DECL_IMPLICIT_INSTANTIATION if no non-template match. | |
266 | * pt.cc (check_explicit_specialization): Check it. | |
267 | * decl2.cc (check_classfn): Call it. | |
268 | ||
df00d103 GA |
269 | 2022-04-07 Patrick Palka <ppalka@redhat.com> |
270 | ||
271 | PR c++/99479 | |
272 | * name-lookup.cc (name_lookup::using_queue): Change to an | |
273 | auto_vec (with 16 elements of internal storage). | |
274 | (name_lookup::queue_namespace): Change return type to void, | |
275 | take queue parameter by reference and adjust function body | |
276 | accordingly. | |
277 | (name_lookup::do_queue_usings): Inline into ... | |
278 | (name_lookup::queue_usings): ... here. As in queue_namespace. | |
279 | (name_lookup::search_unqualified): Don't make queue static, | |
280 | remove length variable, and adjust function body accordingly. | |
281 | ||
282 | 2022-04-07 Jakub Jelinek <jakub@redhat.com> | |
283 | ||
284 | PR tree-optimization/102586 | |
285 | * cp-objcp-common.h (cp_classtype_as_base): Declare. | |
286 | (LANG_HOOKS_CLASSTYPE_AS_BASE): Redefine. | |
287 | * cp-objcp-common.cc (cp_classtype_as_base): New function. | |
288 | ||
289 | 2022-04-07 Jason Merrill <jason@redhat.com> | |
290 | ||
291 | PR c++/101051 | |
292 | * decl.cc (grokdeclarator): Reject conversion with trailing return | |
293 | sooner. | |
294 | ||
295 | 2022-04-07 Jason Merrill <jason@redhat.com> | |
296 | ||
297 | PR c++/101717 | |
298 | * lambda.cc (lambda_expr_this_capture): Check all enclosing | |
299 | lambdas for completeness. | |
300 | ||
301 | 2022-04-07 Jason Merrill <jason@redhat.com> | |
302 | ||
303 | PR c++/105187 | |
304 | * typeck2.cc (store_init_value): Allow TREE_HAS_CONSTRUCTOR for | |
305 | vectors. | |
306 | ||
80eb8ec6 GA |
307 | 2022-04-06 Jakub Jelinek <jakub@redhat.com> |
308 | ||
309 | PR c++/104668 | |
310 | * decl2.cc (splice_template_attributes): Return NULL if *p is | |
311 | error_mark_node. | |
312 | (cplus_decl_attributes): Return early if attributes is | |
313 | error_mark_node. Don't check that later. | |
314 | ||
315 | 2022-04-06 Patrick Palka <ppalka@redhat.com> | |
316 | ||
317 | PR c++/105143 | |
318 | * pt.cc (do_class_deduction): Check complain before attempting | |
319 | to issue a -Wctad-maybe-unsupported warning. | |
320 | ||
321 | 2022-04-06 Jason Merrill <jason@redhat.com> | |
322 | ||
323 | PR c++/104702 | |
324 | * init.cc (build_vec_init): Use a reference for the result. | |
325 | ||
326 | 2022-04-06 Jason Merrill <jason@redhat.com> | |
327 | ||
328 | PR c++/100608 | |
329 | * name-lookup.cc (check_local_shadow): Use -Wshadow=local | |
330 | if exactly one of 'old' and 'decl' is a type. | |
331 | ||
9d84ed68 GA |
332 | 2022-04-05 Jason Merrill <jason@redhat.com> |
333 | ||
334 | PR c++/103852 | |
335 | DR 1286 | |
336 | * pt.cc (do_class_deduction): Pedwarn for renaming alias in C++17. | |
337 | ||
338 | 2022-04-05 Jason Merrill <jason@redhat.com> | |
339 | ||
340 | PR c++/101677 | |
341 | * name-lookup.h (struct cp_binding_level): Add requires_expression | |
342 | bit-field. | |
343 | * parser.cc (cp_parser_requires_expression): Set it. | |
344 | (synthesize_implicit_template_parm): Check it. | |
345 | ||
5e09bb1b GA |
346 | 2022-04-04 Jason Merrill <jason@redhat.com> |
347 | ||
348 | PR c++/101894 | |
349 | * decl.cc (duplicate_decls): Copy DECL_FRIEND_CONTEXT. | |
350 | ||
351 | 2022-04-04 Jason Merrill <jason@redhat.com> | |
352 | ||
353 | PR c++/103852 | |
354 | DR 1286 | |
355 | * pt.cc (get_underlying_template): Compare default template args. | |
356 | ||
8af4270d GA |
357 | 2022-04-03 Benno Evers <benno.evers@tenzir.com> |
358 | Iain Sandoe <iain@sandoe.co.uk> | |
359 | ||
360 | PR c++/103328 | |
361 | * coroutines.cc (morph_fn_to_coro): Reset | |
362 | current_binding_level->blocks. | |
363 | ||
447ac3c5 ML |
364 | 2022-04-01 Jason Merrill <jason@redhat.com> |
365 | ||
366 | Revert: | |
367 | 2022-03-31 Jason Merrill <jason@redhat.com> | |
368 | ||
369 | PR c++/96645 | |
370 | * parser.cc (cp_parser_early_parsing_nsdmi): New. | |
371 | (cp_parser_member_declaration): Call it. | |
372 | ||
373 | 2022-04-01 Jason Merrill <jason@redhat.com> | |
374 | ||
375 | Revert: | |
376 | 2022-03-24 Jason Merrill <jason@redhat.com> | |
377 | ||
378 | PR c++/96645 | |
379 | * cp-tree.h (type_has_default_ctor_to_be_synthesized): Declare. | |
380 | * class.cc (type_has_default_ctor_to_be_synthesized): New. | |
381 | (type_has_non_user_provided_default_constructor_1): Support it. | |
382 | (type_has_non_user_provided_default_constructor): Now a wrapper. | |
383 | * method.cc (complain_about_unparsed_dmi): New. | |
384 | (constructible_expr): Call it. | |
385 | ||
8af4270d GA |
386 | 2022-04-01 Patrick Palka <ppalka@redhat.com> |
387 | ||
388 | PR c++/105110 | |
389 | * pt.cc (unify) <case TEMPLATE_PARM_INDEX>: Drop cv-quals from | |
390 | the argument type of an NTTP before deducing from it. | |
391 | ||
57ad4462 GA |
392 | 2022-03-31 Jason Merrill <jason@redhat.com> |
393 | ||
394 | PR c++/96645 | |
395 | * parser.cc (cp_parser_early_parsing_nsdmi): New. | |
396 | (cp_parser_member_declaration): Call it. | |
397 | ||
150ab50f GA |
398 | 2022-03-30 Patrick Palka <ppalka@redhat.com> |
399 | ||
400 | PR c++/100474 | |
401 | * constraint.cc (diagnose_trait_expr): Handle all remaining | |
402 | traits appropriately. Remove default case. | |
403 | ||
404 | 2022-03-30 Marek Polacek <polacek@redhat.com> | |
405 | ||
406 | PR c++/93280 | |
407 | PR c++/104583 | |
408 | * init.cc (get_nsdmi): Set TARGET_EXPR_DIRECT_INIT_P to in_ctor. | |
409 | ||
410 | 2022-03-30 Jakub Jelinek <jakub@redhat.com> | |
411 | ||
412 | PR c++/105092 | |
413 | * pt.cc (tsubst_omp_clause_decl): When handling iterators, set | |
414 | DECL_CONTEXT of the iterator var to current_function_decl and | |
415 | call pushdecl. | |
416 | ||
417 | 2022-03-30 Jakub Jelinek <jakub@redhat.com> | |
418 | ||
419 | PR c++/105061 | |
420 | * parser.cc (cp_parser_template_introduction): If member_p, temporarily | |
421 | clear parser->colon_corrects_to_scope_p around tentative parsing of | |
422 | nested name specifier. | |
423 | ||
aab0127d GA |
424 | 2022-03-28 Jason Merrill <jason@redhat.com> |
425 | ||
426 | * pt.cc (determine_specialization): Add comment. | |
427 | ||
428 | 2022-03-28 Patrick Palka <ppalka@redhat.com> | |
429 | ||
430 | PR c++/105067 | |
431 | * pt.cc (finish_concept_definition): Check that a concept is | |
432 | declared with exactly one template parameter list. | |
433 | ||
434 | 2022-03-28 Patrick Palka <ppalka@redhat.com> | |
435 | ||
436 | PR c++/105064 | |
437 | * constraint.cc (maybe_substitute_reqs_for): Don't assume | |
438 | DECL_TEMPLATE_INFO is available. | |
439 | ||
440 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
441 | ||
442 | PR c++/105003 | |
443 | PR c++/104008 | |
444 | PR c++/102869 | |
445 | * pt.cc (complex_alias_template_r): walk_tree callback, replacing | |
446 | uses_all_template_parms_r, complex_pack_expansion_r. | |
447 | (complex_alias_template_p): Adjust. | |
448 | * tree.cc (strip_typedefs): Revert r12-7710 change. | |
449 | ||
450 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
451 | ||
452 | PR c++/102071 | |
453 | * init.cc (build_new_1): Include cookie in alignment. Omit | |
454 | constexpr wrapper from alloc_call. | |
455 | ||
456 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
457 | ||
458 | PR c++/103291 | |
459 | * name-lookup.cc (push_local_extern_decl_alias): Call | |
460 | determine_visibility. | |
461 | ||
462 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
463 | ||
464 | PR c++/102123 | |
465 | * pt.cc (tsubst_copy): Use make_unbound_class_template for rewriting | |
466 | a type template reference. | |
467 | ||
468 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
469 | ||
470 | PR c++/103968 | |
471 | * pt.cc (value_dependent_expression_p): Check | |
472 | has_value_dependent_address for conversion to reference. | |
473 | ||
474 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
475 | ||
476 | PR c++/103943 | |
477 | * pt.cc (tsubst_qualified_id): Handle getting SCOPE_REF from | |
478 | tsubst_baselink. | |
479 | (instantiation_dependent_scope_ref_p): Check dependent_scope_p. | |
480 | ||
481 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
482 | ||
483 | PR c++/102045 | |
484 | * call.cc (make_base_init_ok): Call make_used. | |
485 | ||
486 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
487 | ||
488 | PR c++/104847 | |
489 | * mangle.cc (write_expression): Don't write a union designator when | |
490 | undigested. | |
491 | ||
492 | 2022-03-28 Jason Merrill <jason@redhat.com> | |
493 | ||
494 | PR c++/99445 | |
495 | PR c++/103769 | |
496 | * tree.cc (strip_typedefs): Use build_distinct_type_copy. | |
497 | ||
d2906412 GA |
498 | 2022-03-26 Patrick Palka <ppalka@redhat.com> |
499 | ||
500 | PR c++/105050 | |
501 | * constexpr.cc (potential_constant_expression_1) <case IF_STMT>: | |
502 | Clarify error message when a if-stmt is non-constant because its | |
503 | branches are non-constant. | |
504 | ||
505 | 2022-03-26 Patrick Palka <ppalka@redhat.com> | |
506 | ||
507 | PR c++/103455 | |
508 | * call.cc (add_builtin_candidate) <case MEMBER_REF>: Test | |
509 | CLASS_TYPE_P instead of MAYBE_CLASS_TYPE_P. | |
510 | ||
31e989a2 GA |
511 | 2022-03-26 Jakub Jelinek <jakub@redhat.com> |
512 | ||
513 | * parser.cc (cp_parser_postfix_expression) | |
514 | <case RID_BILTIN_CONVERTVECTOR, case RID_BUILTIN_BIT_CAST>: Don't | |
515 | return cp_build_{vec,convert,bit_cast} result right away, instead | |
516 | set postfix_expression to it and break. | |
517 | ||
518 | 2022-03-25 Marek Polacek <polacek@redhat.com> | |
519 | ||
520 | PR c++/104944 | |
521 | * typeck.cc (cxx_sizeof_or_alignof_type): Diagnose alignof(void). | |
522 | (cxx_alignas_expr): Call cxx_sizeof_or_alignof_type with | |
523 | complain == true. | |
524 | ||
6fc4a993 GA |
525 | 2022-03-24 Marek Polacek <polacek@redhat.com> |
526 | ||
527 | PR c++/104284 | |
528 | * decl.cc (check_initializer): Don't call build_aggr_init in | |
529 | a template. | |
530 | ||
531 | 2022-03-24 Jason Merrill <jason@redhat.com> | |
532 | ||
533 | PR c++/96645 | |
534 | * cp-tree.h (type_has_default_ctor_to_be_synthesized): Declare. | |
535 | * class.cc (type_has_default_ctor_to_be_synthesized): New. | |
536 | (type_has_non_user_provided_default_constructor_1): Support it. | |
537 | (type_has_non_user_provided_default_constructor): Now a wrapper. | |
538 | * method.cc (complain_about_unparsed_dmi): New. | |
539 | (constructible_expr): Call it. | |
540 | ||
541 | 2022-03-24 Marek Polacek <polacek@redhat.com> | |
542 | ||
543 | PR c++/102990 | |
544 | * typeck2.cc (massage_init_elt): Avoid folding CONSTRUCTORs. | |
545 | ||
546 | 2022-03-24 Patrick Palka <ppalka@redhat.com> | |
547 | ||
548 | PR c++/104620 | |
549 | * call.cc (build_over_call): Use cxx_constant_value_sfinae | |
550 | instead of cxx_constant_value to evaluate a consteval call. | |
551 | * constexpr.cc (cxx_constant_value_sfinae): Add decl parameter | |
552 | and pass it to cxx_eval_outermost_constant_expr. | |
553 | * cp-tree.h (cxx_constant_value_sfinae): Add decl parameter. | |
554 | * pt.cc (fold_targs_r): Pass NULL_TREE as decl parameter to | |
555 | cxx_constant_value_sfinae. | |
556 | ||
557 | 2022-03-24 Jakub Jelinek <jakub@redhat.com> | |
558 | ||
559 | PR c++/104994 | |
560 | * constexpr.cc (cxx_eval_constant_expression): Don't diagnose passing | |
561 | through extern thread_local declarations. Change wording from | |
562 | declaration to definition. | |
563 | (potential_constant_expression_1): Don't diagnose extern thread_local | |
564 | declarations. Change wording from declared to defined. | |
565 | * decl.cc (start_decl): Likewise. | |
566 | ||
d1ca63a1 GA |
567 | 2022-03-23 Jason Merrill <jason@redhat.com> |
568 | ||
569 | PR c++/103337 | |
570 | * decl.cc (reshape_single_init): New. | |
571 | (reshape_init_class): Use it. | |
572 | ||
573 | 2022-03-23 Jason Merrill <jason@redhat.com> | |
574 | ||
575 | PR c++/105006 | |
576 | * name-lookup.cc (lookup_using_decl): Check that scope is | |
577 | a dependent type before looking for dependent using. | |
578 | ||
579 | 2022-03-23 Jason Merrill <jason@redhat.com> | |
580 | ||
581 | PR c++/105006 | |
582 | * name-lookup.cc (lookup_using_decl): Set DECL_DEPENDENT_P if lookup | |
583 | finds a dependent using. | |
584 | ||
d156bb87 GA |
585 | 2022-03-21 Jason Merrill <jason@redhat.com> |
586 | ||
587 | PR c++/58646 | |
588 | * init.cc (build_vec_init): Check for vla element type. | |
589 | ||
590 | 2022-03-21 Jason Merrill <jason@redhat.com> | |
591 | ||
592 | PR c++/103337 | |
593 | PR c++/102740 | |
594 | PR c++/103299 | |
595 | PR c++/102538 | |
596 | * decl.cc (reshape_init_class): Avoid looking for designator | |
597 | after we found it. | |
598 | (reshape_init_r): Keep looking for designator. | |
599 | ||
600 | 2022-03-21 Jason Merrill <jason@redhat.com> | |
601 | ||
602 | PR c++/101767 | |
603 | * decl.cc (reshape_init_class): Back out of anon struct | |
604 | if a designator doesn't match. | |
605 | ||
8ca61ad1 GA |
606 | 2022-03-18 Jason Merrill <jason@redhat.com> |
607 | ||
608 | PR c++/92918 | |
609 | PR c++/104476 | |
610 | * class.cc (add_method): Avoid adding the same used function twice. | |
611 | (handle_using_decl): Don't add_method. | |
612 | (finish_struct): Don't using op= if we have one already. | |
613 | (maybe_push_used_methods): New. | |
614 | * semantics.cc (finish_member_declaration): Call it. | |
615 | * name-lookup.cc (diagnose_name_conflict): No longer static. | |
616 | (push_class_level_binding): Revert 92918 patch, limit | |
617 | to dependent using. | |
618 | * cp-tree.h: Adjust. | |
619 | ||
620 | 2022-03-18 Jakub Jelinek <jakub@redhat.com> | |
621 | ||
622 | PR c++/104568 | |
623 | * init.cc (build_new_constexpr_heap_type): Remove FULL_SIZE | |
624 | argument and its handling, instead add ITYPE2 argument. Only | |
625 | support COOKIE_SIZE != NULL. | |
626 | (build_new_1): If size is 0, change it to 0 * outer_nelts if | |
627 | outer_nelts is non-NULL. Pass type rather than elt_type to | |
628 | maybe_wrap_new_for_constexpr. | |
629 | * constexpr.cc (build_new_constexpr_heap_type): New function. | |
630 | (cxx_eval_constant_expression) <case CONVERT_EXPR>: | |
631 | If elt_size is zero sized type, try to recover outer_nelts from | |
632 | the size argument to operator new/new[] and pass that as | |
633 | arg_size to build_new_constexpr_heap_type. Pass ctx, | |
634 | non_constant_p and overflow_p to that call too. | |
635 | ||
636 | 2022-03-18 Marek Polacek <polacek@redhat.com> | |
637 | ||
638 | PR c++/104008 | |
639 | * tree.cc (strip_typedefs): Don't strip an alias template when | |
640 | doing so would result in losing a parameter pack. | |
641 | ||
9fc8f278 GA |
642 | 2022-03-16 Patrick Palka <ppalka@redhat.com> |
643 | ||
644 | * search.cc (lookup_member): Simplify by handling all values | |
645 | of protect together in the ambiguous case. Don't modify protect. | |
646 | ||
647 | 2022-03-16 Patrick Palka <ppalka@redhat.com> | |
648 | ||
649 | PR c++/96780 | |
650 | * cp-gimplify.cc (cp_fold) <case CALL_EXPR>: Fold calls to | |
651 | std::move/forward and other cast-like functions into simple | |
652 | casts. | |
653 | ||
14d2ac82 GA |
654 | 2022-03-15 Patrick Palka <ppalka@redhat.com> |
655 | ||
656 | PR c++/103177 | |
657 | * search.cc (lookup_field_info::errstr): Remove this data | |
658 | member. | |
659 | (lookup_field_r): Don't set errstr. | |
660 | (lookup_member): Check ambiguity before checking access. | |
661 | Simplify accordingly after errstr removal. Exit early upon | |
662 | error or empty result. | |
663 | ||
664 | 2022-03-15 Jakub Jelinek <jakub@redhat.com> | |
665 | ||
666 | PR c++/104623 | |
667 | * parser.cc (cp_parser_skip_to_pragma_eol): Don't purge any tokens. | |
668 | ||
510613e7 GA |
669 | 2022-03-14 Jakub Jelinek <jakub@redhat.com> |
670 | ||
671 | PR tree-optimization/102586 | |
672 | * call.cc (build_cxx_call): Diagnose __builtin_clear_padding where | |
673 | first argument's type is pointer to non-trivially-copyable type unless | |
674 | it is address of a variable or parameter. | |
675 | ||
57eeedda GA |
676 | 2022-03-12 Patrick Palka <ppalka@redhat.com> |
677 | ||
678 | PR c++/104641 | |
679 | * cp-tree.h (tsubst_flags::tf_tst_ok): New flag. | |
680 | * decl.cc (make_typename_type): Allow a typename-specifier to | |
681 | resolve to a template when tf_tst_ok, in which case return | |
682 | a CTAD placeholder for the template. | |
683 | * pt.cc (tsubst_decl) <case VAR_DECL>: Set tf_tst_ok when | |
684 | substituting the type. | |
685 | (tsubst): Clear tf_tst_ok and remember if it was set. | |
686 | <case TYPENAME_TYPE>: Pass tf_tst_ok to make_typename_type | |
687 | appropriately. | |
688 | (tsubst_copy) <case CAST_EXPR>: Set tf_tst_ok when substituting | |
689 | the type. | |
690 | (tsubst_copy_and_build) <case CAST_EXPR>: Likewise. | |
691 | <case CONSTRUCTOR>: Likewise. | |
692 | ||
693 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
694 | ||
695 | PR c++/104622 | |
696 | * call.cc (missing_conversion_p): Define. | |
697 | (add_candidates): Use it. | |
698 | * pt.cc (check_non_deducible_conversion): Change type of strict | |
699 | parameter to unification_kind_t and directly test for DEDUCE_CALL. | |
700 | ||
701 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
702 | ||
703 | PR c++/104527 | |
704 | * constraint.cc (normalize_atom): Set | |
705 | ATOMIC_CONSTR_EXPR_FROM_CONCEPT_P appropriately. | |
706 | (get_mapped_args): Make static, adjust parameters. Always | |
707 | return a vector whose depth corresponds to the template depth of | |
708 | the context of the atomic constraint expression. Micro-optimize | |
709 | by passing false as exact to safe_grow_cleared and by collapsing | |
710 | a multi-level depth-one argument vector. | |
711 | (satisfy_atom): Adjust call to get_mapped_args and | |
712 | diagnose_atomic_constraint. | |
713 | (diagnose_atomic_constraint): Replace map parameter with an args | |
714 | parameter. | |
715 | * cp-tree.h (ATOMIC_CONSTR_EXPR_FROM_CONCEPT_P): Define. | |
716 | (get_mapped_args): Remove declaration. | |
717 | ||
718 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
719 | Jason Merrill <jason@redhat.com> | |
720 | ||
721 | PR c++/98644 | |
722 | * constexpr.cc (mark_non_constant): Define, split out from ... | |
723 | (cxx_eval_outermost_constant_expr): ... here. | |
724 | (maybe_constant_value): Use it. | |
725 | ||
726 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
727 | ||
728 | * semantics.cc (finish_unary_fold_expr): Use input_location | |
729 | instead of UNKNOWN_LOCATION. | |
730 | (finish_binary_fold_expr): Likewise. | |
731 | ||
732 | 2022-03-12 Thomas Schwinge <thomas@codesourcery.com> | |
733 | ||
734 | PR other/65095 | |
735 | * semantics.cc (handle_omp_array_sections_1) | |
736 | (cp_oacc_check_attachments): Call 'user_omp_clause_code_name' | |
737 | instead of 'c_omp_map_clause_name'. | |
738 | ||
5e28be89 GA |
739 | 2022-03-10 Marek Polacek <polacek@redhat.com> |
740 | ||
741 | PR c++/104608 | |
742 | * parser.cc (cp_parser_template_name): Repeat lookup of | |
743 | TYPE_DECLs. | |
744 | ||
745 | 2022-03-10 Marek Polacek <polacek@redhat.com> | |
746 | ||
747 | PR c++/104752 | |
748 | * semantics.cc (finish_compound_literal): Disallow auto{x} for | |
749 | is_constrained_auto. | |
750 | * typeck2.cc (build_functional_cast_1): Likewise. | |
751 | ||
752 | 2022-03-10 Marek Polacek <polacek@redhat.com> | |
753 | ||
754 | PR c++/104846 | |
755 | * decl.cc (grokdeclarator): Check FUNC_OR_METHOD_TYPE_P before giving | |
756 | data member errors. | |
757 | ||
758 | 2022-03-10 Jakub Jelinek <jakub@redhat.com> | |
759 | ||
760 | PR c++/103460 | |
761 | * decl.cc (grok_op_properties): Allow variadic operator[] for | |
762 | C++23. | |
763 | ||
764 | 2022-03-10 Roger Sayle <roger@nextmovesoftware.com> | |
765 | ||
766 | PR c++/95999 | |
767 | * decl.cc (finish_enum_value_list): If VALUE isn't an INTEGER_CST | |
768 | consider it to be zero (i.e. treat it like error_mark_node). | |
769 | (build_enumerator): Likewise, if PREV_VALUE isn't an INTEGER_CST, | |
770 | set VALUE to error_mark_node. | |
771 | ||
772 | 2022-03-10 Roger Sayle <roger@nextmovesoftware.com> | |
773 | ||
774 | PR c++/39751 | |
775 | * parser.cc (cp_parser_late_parsing_for_member): Confirm the token | |
776 | stream hasn't been purged before processing DECL_PENDING_INLINE. | |
777 | ||
8cc4f9cd GA |
778 | 2022-03-09 Patrick Palka <ppalka@redhat.com> |
779 | ||
780 | PR c++/104823 | |
781 | * except.cc (build_noexcept_spec): Strengthen dependence check | |
782 | to instantiation_dependent_expression_p. | |
783 | * parser.cc (cp_parser_parenthesized_expression_list_elt): | |
784 | Remove fold_expr_p parameter, and don't call | |
785 | instantiate_non_dependent_expr. | |
786 | (cp_parser_parenthesized_expression_list): Adjust accordingly. | |
787 | * pt.cc (expand_integer_pack): Strengthen dependence check | |
788 | to instantiation_dependent_expression_p. | |
789 | (instantiate_non_dependent_expr_internal): Adjust comment. | |
790 | (instantiate_non_dependent_expr_sfinae): Likewise. Drop | |
791 | the potentially-constant check, and relax and turn the | |
792 | dependence check into a checking assert. | |
793 | (instantiate_non_dependent_or_null): Adjust comment. | |
794 | * semantics.cc (finish_decltype_type): Keep | |
795 | processing_template_decl cleared after calling | |
796 | instantiate_non_dependent_expr_sfinae. | |
797 | ||
798 | 2022-03-09 Patrick Palka <ppalka@redhat.com> | |
799 | ||
800 | PR c++/102137 | |
801 | PR c++/87820 | |
802 | * cp-tree.h (is_copy_initialization): Declare. | |
803 | * decl.cc (cp_finish_decl): Set LOOKUP_ONLYCONVERTING | |
804 | when is_copy_initialization is true. | |
805 | * init.cc (build_aggr_init): Split out copy-initialization | |
806 | check into ... | |
807 | (is_copy_initialization): ... here. | |
808 | * pt.cc (instantiate_decl): Pass 0 instead of | |
809 | LOOKUP_ONLYCONVERTING as flags to cp_finish_decl. | |
810 | ||
811 | 2022-03-09 Patrick Palka <ppalka@redhat.com> | |
812 | ||
813 | PR c++/65396 | |
814 | * cp-tree.h (merge_default_template_args): Declare. | |
815 | * decl.cc (merge_default_template_args): Define, factored out | |
816 | from redeclare_class_template. | |
817 | (duplicate_decls): Use it when merging member function template | |
818 | and free function declarations. | |
819 | * pt.cc (redeclare_class_template): Factor out default argument | |
820 | merging logic into merge_default_template_args. Improve location | |
821 | of a note when there's a template parameter kind mismatch. | |
822 | ||
823 | 2022-03-09 Jakub Jelinek <jakub@redhat.com> | |
824 | ||
825 | PR c/104711 | |
826 | * constexpr.cc (cxx_eval_check_shift_p): Use TYPE_OVERFLOW_WRAPS | |
827 | instead of TYPE_UNSIGNED. | |
828 | * typeck.cc (cp_build_binary_op): Don't emit | |
829 | -Wshift-negative-value warning if TYPE_OVERFLOW_WRAPS. | |
830 | ||
8d038a84 GA |
831 | 2022-03-08 Roger Sayle <roger@nextmovesoftware.com> |
832 | ||
833 | PR c++/96440 | |
834 | * decl.cc (start_decl): Defend against prefix_attributes being | |
835 | error_mark_node. | |
836 | ||
837 | 2022-03-08 Roger Sayle <roger@nextmovesoftware.com> | |
838 | ||
839 | PR c++/96437 | |
840 | * parser.cc (synthesize_implicit_template_parm): Check that | |
841 | TREE_VALUE (new_parm) isn't error_mark_node before setting its | |
842 | DECL_VIRTUAL_P. | |
843 | ||
844 | 2022-03-08 Roger Sayle <roger@nextmovesoftware.com> | |
845 | ||
846 | PR c++/96329 | |
847 | * parser.cc (cp_parser_linkage_specification): Treat the case where | |
848 | linkage is error_mark_node as "invalid linkage-specification". | |
849 | ||
850 | 2022-03-08 Marek Polacek <polacek@redhat.com> | |
851 | ||
852 | PR c++/104108 | |
853 | * pt.cc (convert_nontype_argument): Recompute | |
854 | value_dependent_expression_p after build_converted_constant_expr. | |
855 | ||
856 | 2022-03-08 Marek Polacek <polacek@redhat.com> | |
857 | ||
858 | * decl2.cc (is_late_template_attribute): Do not defer attribute | |
859 | unavailable. | |
860 | * pt.cc (tsubst_enum): Set TREE_UNAVAILABLE. | |
861 | ||
862 | 2022-03-08 Jakub Jelinek <jakub@redhat.com> | |
863 | ||
864 | PR c++/104806 | |
865 | * search.cc (lookup_field_fuzzy_info::fuzzy_lookup_field): Ignore | |
866 | identifiers with space at the end. | |
867 | ||
e6533e2e GA |
868 | 2022-03-07 Jason Merrill <jason@redhat.com> |
869 | ||
870 | PR c++/104618 | |
871 | * decl2.cc (mark_single_function): Look through parens and location | |
872 | wrapper. | |
873 | * typeck.cc (cp_build_addr_expr_1): Not here. | |
874 | ||
875 | 2022-03-07 Jakub Jelinek <jakub@redhat.com> | |
876 | ||
877 | * parser.cc (cp_parser_omp_clause_map): Add missing space in string | |
878 | literal. | |
879 | ||
880 | 2022-03-07 Jakub Jelinek <jakub@redhat.com> | |
881 | ||
882 | * cvt.cc: Fix up duplicated word issue in a comment. | |
883 | * pt.cc: Likewise. | |
884 | * module.cc: Likewise. | |
885 | * coroutines.cc: Likewise. | |
886 | ||
8d96e14c GA |
887 | 2022-03-04 Nathan Sidwell <nathan@acm.org> |
888 | ||
889 | * mangle.cc (is_std_substitution): Check global module. | |
890 | (is_std_substitution_char): Return bool. | |
891 | ||
892 | 2022-03-04 Nathan Sidwell <nathan@acm.org> | |
893 | ||
894 | * cp-tree.h (mangle_identifier): Replace with ... | |
895 | (mangle_module_component): ... this. | |
896 | * mangle.cc (dump_substitution_candidates): Adjust. | |
897 | (add_substitution): Likewise. | |
898 | (find_substitution): Likewise. | |
899 | (unmangled_name_p): Likewise. | |
900 | (mangle_module_substitution): Reimplement. | |
901 | (mangle_module_component): New. | |
902 | (write_module, maybe_write_module): Adjust. | |
903 | (write_name): Drop modules here. | |
904 | (write_unqualified): Do them here instead. | |
905 | (mangle_global_init): Adjust. | |
906 | * module.cc (module_state::mangle): Adjust. | |
907 | (mangle_module): Likewise. | |
908 | (get_originating_module): Adjust. | |
909 | ||
a35f1697 GA |
910 | 2022-02-28 Marek Polacek <polacek@redhat.com> |
911 | ||
912 | PR c++/104682 | |
913 | * cp-tree.h (build_enumerator): Adjust. | |
914 | * decl.cc (finish_enum): Make it return the new decl. | |
915 | * pt.cc (tsubst_enum): Propagate TREE_DEPRECATED and TREE_UNAVAILABLE. | |
916 | ||
917 | 2022-02-28 Marek Polacek <polacek@redhat.com> | |
918 | ||
919 | PR c++/104667 | |
920 | * decl2.cc (is_late_template_attribute): Cope with a decl without | |
921 | a type. | |
922 | ||
88c1b038 GA |
923 | 2022-02-27 Jason Merrill <jason@redhat.com> |
924 | ||
925 | PR c++/104618 | |
926 | * typeck.cc (cp_build_addr_expr_1): Also | |
927 | maybe_undo_parenthesized_ref. | |
928 | ||
756a6185 GA |
929 | 2022-02-24 Martin Liska <mliska@suse.cz> |
930 | ||
931 | * pt.cc (defarg_insts_for): Use braces for subobject. | |
932 | ||
5a9ba3f2 GA |
933 | 2022-02-18 Patrick Palka <ppalka@redhat.com> |
934 | ||
935 | PR c++/94944 | |
936 | * pt.cc (maybe_instantiate_noexcept): For non-static member | |
937 | functions, set current_class_ptr/ref to the specialized 'this' | |
938 | instead. | |
939 | ||
0bdb0498 GA |
940 | 2022-02-17 Jason Merrill <jason@redhat.com> |
941 | ||
942 | PR c++/104539 | |
943 | * pt.cc (mark_decl_instantiated): Don't clear DECL_COMDAT. | |
944 | ||
945 | 2022-02-17 Jason Merrill <jason@redhat.com> | |
946 | ||
947 | PR c++/90451 | |
948 | * decl2.cc (mark_single_function): New. | |
949 | * cp-tree.h: Declare it. | |
950 | * typeck.cc (cp_build_addr_expr_1): mark_used when making a PMF. | |
951 | * semantics.cc (finish_qualified_id_expr): Not here. | |
952 | (finish_id_expression_1): Or here. | |
953 | (finish_decltype_type): Call mark_single_function. | |
954 | * cvt.cc (convert_to_void): And here. | |
955 | * pt.cc (convert_nontype_argument): And here. | |
956 | * init.cc (build_offset_ref): Adjust assert. | |
957 | ||
958 | 2022-02-17 Patrick Palka <ppalka@redhat.com> | |
959 | ||
960 | PR c++/104565 | |
961 | * semantics.cc (finish_compound_literal): Don't perform | |
962 | non-dependent expr folding before calling check_narrowing. | |
963 | ||
cb3afcd2 GA |
964 | 2022-02-16 Patrick Palka <ppalka@redhat.com> |
965 | ||
966 | PR c++/104507 | |
967 | * constexpr.cc (potential_constant_expression_1) | |
968 | <case NON_DEPENDENT_EXPR>: Return false instead of recursing. | |
969 | Assert tf_error isn't set. | |
970 | ||
875e493b GA |
971 | 2022-02-15 Jason Merrill <jason@redhat.com> |
972 | ||
973 | PR c++/104107 | |
974 | PR c++/95036 | |
975 | * pt.cc (coerce_template_template_parms): Take full parms. | |
976 | Avoid adding too much of outer_args. | |
977 | (coerce_template_template_parm): Adjust. | |
978 | (template_template_parm_bindings_ok_p): Adjust. | |
979 | (convert_template_argument): Adjust. | |
980 | ||
1f8a09d2 GA |
981 | 2022-02-14 Jakub Jelinek <jakub@redhat.com> |
982 | ||
983 | PR c++/104513 | |
984 | * constexpr.cc (potential_constant_expression_1) <case GOTO_EXPR>: | |
985 | Don't punt if returns (target). | |
986 | ||
e8d68f0a GA |
987 | 2022-02-11 Jakub Jelinek <jakub@redhat.com> |
988 | ||
989 | PR c++/104472 | |
990 | * constexpr.cc (cxx_eval_internal_function) <case IFN_VEC_CONVERT>: | |
991 | Only return fold_const_call result if it is non-NULL. Otherwise | |
992 | fall through into the default: case to return t, set *non_constant_p | |
993 | and emit diagnostics if needed. | |
994 | ||
a645583d GA |
995 | 2022-02-10 Jason Merrill <jason@redhat.com> |
996 | ||
997 | * module.cc (depset::hash::add_specializations): Use | |
998 | STRIP_TEMPLATE. | |
999 | ||
1000 | 2022-02-10 Tobias Burnus <tobias@codesourcery.com> | |
1001 | ||
1002 | PR c++/102204 | |
1003 | * decl2.cc (cp_omp_mappable_type_1): Remove check for virtual | |
1004 | members as those are permitted since OpenMP 5.0. | |
1005 | ||
1006 | 2022-02-10 Patrick Palka <ppalka@redhat.com> | |
1007 | ||
1008 | * pt.cc (filter_memfn_lookup): Handle dependent USING_DECL | |
1009 | better. | |
1010 | ||
1011 | 2022-02-10 Marcel Vollweiler <marcel@codesourcery.com> | |
1012 | ||
1013 | * parser.cc (cp_parser_omp_clause_name): Parse 'has_device_addr' clause. | |
1014 | (cp_parser_omp_var_list_no_open): Handle array sections. | |
1015 | (cp_parser_omp_all_clauses): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR | |
1016 | case. | |
1017 | (cp_parser_omp_target_update): Added HAS_DEVICE_ADDR to OMP_CLAUSE_MASK. | |
1018 | * semantics.cc (handle_omp_array_sections): Handle clause restrictions. | |
1019 | (finish_omp_clauses): Handle array sections. | |
1020 | ||
3adf509f GA |
1021 | 2022-02-09 Patrick Palka <ppalka@redhat.com> |
1022 | ||
1023 | PR c++/104432 | |
1024 | * call.cc (build_new_method_call): When a non-dependent call | |
1025 | resolves to a specialization of a member template, always build | |
1026 | the pruned overload set using the member template, not the | |
1027 | specialization. | |
1028 | * pt.cc (filter_memfn_lookup): New parameter newtype. Simplify | |
1029 | and correct how members from the new lookup set are matched to | |
1030 | those from the old one. | |
1031 | (tsubst_baselink): Pass binfo_type as newtype to | |
1032 | filter_memfn_lookup. | |
1033 | ||
1034 | 2022-02-09 Jason Merrill <jason@redhat.com> | |
1035 | ||
1036 | PR c++/103752 | |
1037 | * module.cc (trees_out::core_vals): Stream explicit specifier. | |
1038 | (trees_in::core_vals): Likewise. | |
1039 | * pt.cc (store_explicit_specifier): No longer static. | |
1040 | (tsubst_function_decl): Clear DECL_HAS_DEPENDENT_EXPLICIT_SPEC_P. | |
1041 | * cp-tree.h (lookup_explicit_specifier): Declare. | |
1042 | ||
1043 | 2022-02-09 Jason Merrill <jason@redhat.com> | |
1044 | ||
1045 | PR c++/96876 | |
1046 | * typeck2.cc (split_nonconstant_init_1): Push cleanups for | |
1047 | preceding members with constant initialization. | |
1048 | (maybe_push_temp_cleanup): Do nothing if -fno-exceptions. | |
1049 | ||
2a2fda2d GA |
1050 | 2022-02-08 Jakub Jelinek <jakub@redhat.com> |
1051 | ||
1052 | PR c++/104379 | |
1053 | * name-lookup.cc (check_local_shadow): When diagnosing shadowing | |
1054 | of a member or global declaration, add warning suppression for | |
1055 | the decl and don't warn again on it. | |
1056 | ||
1057 | 2022-02-08 Jakub Jelinek <jakub@redhat.com> | |
1058 | ||
1059 | PR c++/104403 | |
1060 | * constexpr.cc (cxx_eval_constant_expression): Don't assert DECL_EXPRs | |
1061 | of TREE_STATIC vars may only appear in -std=c++23. | |
1062 | ||
1063 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
1064 | ||
1065 | PR c++/80951 | |
1066 | * pt.cc (uses_deducible_template_parms): Consider the | |
1067 | noexcept-spec of a function type. | |
1068 | ||
1069 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
1070 | ||
1071 | PR c++/104410 | |
1072 | * constraint.cc (satisfaction_value): Relax assert to accept | |
1073 | cv-qualified bool. | |
1074 | ||
1075 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
1076 | ||
1077 | PR c++/103706 | |
1078 | * pt.cc (preserve_args): New function. | |
1079 | (tsubst_lambda_expr): Use it when setting LAMBDA_EXPR_REGEN_INFO. | |
1080 | ||
1081 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
1082 | ||
1083 | PR c++/103706 | |
1084 | * constraint.cc (satisfy_declaration_constraints): Use | |
1085 | lambda_regenerating_args instead. | |
1086 | * cp-tree.h (lambda_regenerating_args): Declare. | |
1087 | * pt.cc (lambda_regenerating_args): Define, split out from | |
1088 | satisfy_declaration_constraints. | |
1089 | (do_auto_deduction): Use lambda_regenerating_args to obtain the | |
1090 | full set of outer template arguments for satisfaction when | |
1091 | inside a lambda. | |
1092 | ||
353f8fcc GA |
1093 | 2022-02-06 Patrick Palka <ppalka@redhat.com> |
1094 | ||
1095 | PR c++/96242 | |
1096 | * decl2.cc (mark_used): Directly synthesize a DECL_MAYBE_DELETED | |
1097 | fn by calling maybe_synthesize_method instead of relying on | |
1098 | maybe_instantiate_noexcept. Move call to m_i_n after the | |
1099 | DECL_DELETED_FN handling. | |
1100 | * pt.cc (maybe_instantiate_noexcept): Restrict DECL_MAYBE_DELETED | |
1101 | fn synthesis to only those with an implicit noexcept-spec, and | |
1102 | return !DECL_DELETED_FN instead of !DECL_MAYBE_DELETED afterwards. | |
1103 | ||
1104 | 2022-02-06 Jakub Jelinek <jakub@redhat.com> | |
1105 | ||
1106 | PR c++/89074 | |
1107 | PR c++/104033 | |
1108 | * constexpr.cc (cxx_eval_binary_expression): Temporarily set | |
1109 | folding_cxx_constexpr. | |
1110 | ||
661109b0 GA |
1111 | 2022-02-05 Jason Merrill <jason@redhat.com> |
1112 | ||
1113 | PR c++/104300 | |
1114 | PR c++/92385 | |
1115 | * cp-tree.h (get_vec_init_expr): New. | |
1116 | (target_expr_needs_replace): New. | |
1117 | * cp-gimplify.cc (cp_gimplify_init_expr): Use it. | |
1118 | (struct cp_fold_data): New. | |
1119 | (cp_fold_r): Only genericize inits at end of fn. | |
1120 | (cp_fold_function): Here. | |
1121 | (cp_fully_fold_init): Not here. | |
1122 | * init.cc (build_vec_init): Use get_vec_init_expr. | |
1123 | * tree.cc (build_vec_init_expr): Likewise. | |
1124 | * typeck2.cc (split_nonconstant_init_1): Likewise. | |
1125 | (process_init_constructor): Wrap VEC_INIT_EXPR in | |
1126 | TARGET_EXPR. | |
1127 | ||
1128 | 2022-02-05 Jason Merrill <jason@redhat.com> | |
1129 | ||
1130 | * pt.cc (iterative_hash_template_arg): Add comment. | |
1131 | ||
682ede39 GA |
1132 | 2022-02-03 Patrick Palka <ppalka@redhat.com> |
1133 | ||
1134 | PR c++/104079 | |
1135 | * pt.cc (value_dependent_noexcept_spec_p): New predicate split | |
1136 | out from ... | |
1137 | (dependent_type_p_r): ... here. | |
1138 | (instantiation_dependent_r): Use value_dependent_noexcept_spec_p | |
1139 | to consider dependence of a noexcept-spec before C++17. | |
1140 | * tree.cc (fixup_deferred_exception_variants): Clear | |
1141 | TYPE_DEPENDENT_P_VALID. | |
1142 | ||
1143 | 2022-02-03 Jason Merrill <jason@redhat.com> | |
1144 | ||
1145 | PR c++/104302 | |
1146 | * decl.cc (maybe_deduce_size_from_array_init): Give up | |
1147 | on type-dependent init. | |
1148 | (cp_complete_array_type): Only call reshape_init for character | |
1149 | array. | |
1150 | ||
ae7e4af9 GA |
1151 | 2022-02-01 Jason Merrill <jason@redhat.com> |
1152 | ||
1153 | PR c++/103186 | |
1154 | * pt.cc (defarg_inst): Use tree_vec_map_cache_hasher. | |
1155 | (defarg_insts_for): New. | |
1156 | (tsubst_default_argument): Adjust. | |
1157 | ||
1bb52662 GA |
1158 | 2022-01-31 Marek Polacek <polacek@redhat.com> |
1159 | ||
1160 | PR c++/102414 | |
1161 | PR c++/101874 | |
1162 | * decl.cc (create_array_type_for_decl): Use template_placeholder_p. | |
1163 | Sorry on a variable-length array of auto. | |
1164 | ||
1165 | 2022-01-31 Marek Polacek <polacek@redhat.com> | |
1166 | ||
1167 | PR c++/102434 | |
1168 | * class.cc (finish_struct): Don't allow union initializer_list. | |
1169 | ||
1170 | 2022-01-31 Patrick Palka <ppalka@redhat.com> | |
1171 | ||
1172 | PR c++/104294 | |
1173 | * pt.cc (ctor_deduction_guides_for): Correct computation of | |
1174 | outer_args. | |
1175 | ||
1176 | 2022-01-31 Patrick Palka <ppalka@redhat.com> | |
1177 | ||
1178 | PR c++/104291 | |
1179 | * pt.cc (for_each_template_parm_r) <case CONSTRUCTOR>: Clear | |
1180 | walk_subtrees if !include_nondeduced_p. Simplify given that | |
1181 | cp_walk_subtrees already walks TYPE_PTRMEMFUNC_FN_TYPE_RAW. | |
1182 | ||
f6f2d6cf GA |
1183 | 2022-01-28 Patrick Palka <ppalka@redhat.com> |
1184 | Jason Merrill <jason@redhat.com> | |
1185 | ||
1186 | PR c++/92752 | |
1187 | * typeck.cc (build_ptrmemfunc): Cast a nullptr constant to the | |
1188 | unqualified pointer type not the qualified one. | |
1189 | ||
1190 | 2022-01-28 Patrick Palka <ppalka@redhat.com> | |
1191 | ||
1192 | PR c++/103341 | |
1193 | * decl.cc (cp_finish_decl): Pass the template arguments of a | |
1194 | variable template specialization or a templated static data | |
1195 | member to do_auto_deduction when the auto is constrained. | |
1196 | ||
1197 | 2022-01-28 Jason Merrill <jason@redhat.com> | |
1198 | ||
1199 | PR c++/100198 | |
1200 | PR c++/100030 | |
1201 | PR c++/100282 | |
1202 | * parser.cc (cp_parser_enumerator_definition): Sorry on parameter | |
1203 | pack in lambda. | |
1204 | (cp_parser_class_head): And in class attributes. | |
1205 | * pt.cc (check_for_bare_parameter_packs): Sorry instead of error | |
1206 | in lambda. | |
1207 | ||
99f17e99 GA |
1208 | 2022-01-27 Jason Merrill <jason@redhat.com> |
1209 | ||
1210 | PR c++/104245 | |
1211 | PR c++/51344 | |
1212 | * decl2.cc (save_template_attributes): Take late attrs as parm. | |
1213 | (cplus_decl_attributes): Call it after decl_attributes, | |
1214 | splice_template_attributes before. | |
1215 | ||
1216 | 2022-01-27 Patrick Palka <ppalka@redhat.com> | |
1217 | ||
1218 | PR c++/99895 | |
1219 | * call.cc (build_over_call): For a non-dependent member call, | |
1220 | build up a CALL_EXPR using a COMPONENT_REF callee, as in | |
1221 | build_new_method_call. | |
1222 | * pt.cc (build_non_dependent_expr): Don't wrap PARM_DECL either. | |
1223 | * tree.cc (build_min_non_dep_op_overload): Adjust accordingly | |
1224 | after the build_over_call change. | |
1225 | ||
1226 | 2022-01-27 Patrick Palka <ppalka@redhat.com> | |
1227 | ||
1228 | PR c++/92944 | |
1229 | PR c++/103678 | |
1230 | * parser.cc (cp_parser_class_head): Update 'type' with the result | |
1231 | of maybe_process_partial_specialization in the | |
1232 | nested_name_specifier branch. Refactor nearby code to accomodate | |
1233 | that maybe_process_partial_specialization returns a _TYPE, not a | |
1234 | TYPE_DECL, and eliminate local variable 'class_type' in passing. | |
1235 | ||
1236 | 2022-01-27 Marek Polacek <polacek@redhat.com> | |
1237 | ||
1238 | PR c++/101988 | |
1239 | * decl.cc (create_array_type_for_decl): Reject forming an array of | |
1240 | placeholder for a deduced class type. | |
1241 | ||
eaa59070 GA |
1242 | 2022-01-26 Jason Merrill <jason@redhat.com> |
1243 | ||
1244 | PR c++/104206 | |
1245 | PR c++/101072 | |
1246 | * semantics.cc (finish_compound_literal): Restore VECTOR_TYPE check. | |
1247 | ||
1248 | 2022-01-26 Jakub Jelinek <jakub@redhat.com> | |
1249 | ||
1250 | PR c++/104226 | |
1251 | * constexpr.cc (init_subob_ctx): For vector ctors containing | |
1252 | vector elements, ensure appending to the same ctor instead of | |
1253 | creating another one. | |
1254 | ||
1255 | 2022-01-26 Marek Polacek <polacek@redhat.com> | |
1256 | ||
1257 | PR target/104213 | |
1258 | * decl.cc (finish_constructor_body): Suppress -Wuse-after-free. | |
1259 | (finish_destructor_body): Likewise. | |
1260 | * optimize.cc (build_delete_destructor_body): Likewise. | |
1261 | ||
1262 | 2022-01-26 Jason Merrill <jason@redhat.com> | |
1263 | ||
1264 | PR c++/104235 | |
1265 | * parser.cc (cp_parser_template_name): Repeat lookup of USING_DECL. | |
1266 | ||
1267 | 2022-01-26 Jason Merrill <jason@redhat.com> | |
1268 | ||
1269 | PR c++/103057 | |
1270 | * pt.cc (tsubst_aggr_type): Call tsubst for alias template | |
1271 | specialization. | |
1272 | ||
e0b8716f GA |
1273 | 2022-01-25 Patrick Palka <ppalka@redhat.com> |
1274 | ||
1275 | PR c++/101532 | |
1276 | PR c++/104225 | |
1277 | * decl2.cc (mark_used): Don't consider maybe_instantiate_noexcept | |
1278 | on a deleted function. | |
1279 | ||
1280 | 2022-01-25 Jason Merrill <jason@redhat.com> | |
1281 | ||
1282 | PR c++/59950 | |
1283 | * call.cc (build_over_call): Use cp_build_indirect_ref. | |
1284 | ||
bb99171b GA |
1285 | 2022-01-24 Patrick Palka <ppalka@redhat.com> |
1286 | ||
1287 | PR c++/104197 | |
1288 | * pt.cc (make_auto_1): Use -1 as a placeholder default argument | |
1289 | for level. | |
1290 | ||
1291 | 2022-01-24 Patrick Palka <ppalka@redhat.com> | |
1292 | ||
1293 | PR c++/104173 | |
1294 | * typeck.cc (build_class_member_access_expr): Extend | |
1295 | unary_complex_lvalue result adjustment to preserve all | |
1296 | rvalues, not just xvalues. | |
1297 | ||
0c940703 GA |
1298 | 2022-01-23 Will Wray <wjwray@gmail.com> |
1299 | ||
1300 | PR c++/55227 | |
1301 | * decl.cc (reshape_init_r): Only call has_designator_check when | |
1302 | first_initializer_p or for the inner constructor element. | |
1303 | (cp_complete_array_type): Call reshape_init on braced-init-list. | |
1304 | ||
1305 | 2022-01-23 Jason Merrill <jason@redhat.com> | |
1306 | ||
1307 | PR c++/104182 | |
1308 | * cp-gimplify.cc (cp_genericize_target_expr): Make sure nothing | |
1309 | has set DECL_INITIAL on a TARGET_EXPR slot. | |
1310 | * tree.cc (is_local_temp): Don't check DECL_CONTEXT. | |
1311 | ||
1312 | 2022-01-23 Jason Merrill <jason@redhat.com> | |
1313 | ||
1314 | PR c++/101072 | |
1315 | * cp-tree.h (build_implicit_conv_flags): Declare. | |
1316 | * call.cc (build_implicit_conv_flags): Split out from... | |
1317 | (perform_implicit_conversion_flags): ...here. | |
1318 | * decl.cc (check_initializer): Use it. | |
1319 | * pt.cc (tsubst_copy_and_build): Remove TARGET_EXPR handling. | |
1320 | * semantics.cc (finish_compound_literal): Don't treat | |
1321 | scalar values like CONSTRUCTORs. | |
1322 | ||
9dd44357 GA |
1323 | 2022-01-21 Jason Merrill <jason@redhat.com> |
1324 | ||
1325 | * semantics.cc (find_failing_clause): Return expr if not | |
1326 | decomposable. | |
1327 | (finish_static_assert): Show constant values in failing | |
1328 | comparison. | |
1329 | ||
1330 | 2022-01-21 Jason Merrill <jason@redhat.com> | |
1331 | ||
1332 | PR c++/104084 | |
1333 | PR c++/20040 | |
1334 | * init.cc (build_new_1): Only pull out TARGET_EXPR_INITIAL if | |
1335 | alloc_expr is a TARGET_EXPR. | |
1336 | ||
1337 | 2022-01-21 Marek Polacek <polacek@redhat.com> | |
1338 | ||
1339 | PR c++/101715 | |
1340 | * tree.cc (fixup_deferred_exception_variants): Remove duplicate | |
1341 | variants after parsing the exception specifications. | |
1342 | ||
1343 | 2022-01-21 Jason Merrill <jason@redhat.com> | |
1344 | ||
1345 | PR c++/104139 | |
1346 | PR c++/103681 | |
1347 | * class.cc (end_of_class): Use base_binfo. | |
1348 | ||
5fa55d55 GA |
1349 | 2022-01-20 Jason Merrill <jason@redhat.com> |
1350 | ||
1351 | PR c++/101405 | |
1352 | * decl.cc (reshape_init_class): Reject designator for a member of | |
1353 | another class. | |
1354 | ||
1355 | 2022-01-20 Patrick Palka <ppalka@redhat.com> | |
1356 | ||
1357 | PR c++/91911 | |
1358 | PR c++/103672 | |
1359 | * pt.cc (keep_template_parm): Punt on a level 0 template parm. | |
1360 | (tsubst_decl) <case VAR_DECL>: Remove !CHECKING_P safeguard. | |
1361 | (tsubst) <case TEMPLATE_TYPE_PARM>: Handle CTAD placeholders | |
1362 | specially. | |
1363 | (make_auto_1): Add defaulted 'level' parameter. | |
1364 | (make_template_placeholder): Pass 0 as 'level' to make_auto_1. | |
1365 | ||
1366 | 2022-01-20 Patrick Palka <ppalka@redhat.com> | |
1367 | ||
1368 | * decl.cc (grokdeclarator): Diagnose a CTAD placeholder as | |
1369 | function return type even when !funcdecl_p. | |
1370 | ||
1371 | 2022-01-20 Martin Liska <mliska@suse.cz> | |
1372 | ||
1373 | PR c++/104134 | |
1374 | * error.cc (dump_aggr_type): Partially disable the warning. | |
1375 | ||
1376 | 2022-01-20 Jason Merrill <jason@redhat.com> | |
1377 | ||
1378 | PR c++/102300 | |
1379 | * parser.cc (cp_parser_template_name): Use dependent_scope_p. | |
1380 | ||
fe1ad141 GA |
1381 | 2022-01-19 David Malcolm <dmalcolm@redhat.com> |
1382 | ||
1383 | * cp-lang.cc (selftest::run_cp_tests): Update calls for .c to .cc | |
1384 | renaming. | |
1385 | * cp-tree.h (cp_pt_c_tests): Rename to... | |
1386 | (cp_pt_cc_tests): ...this. | |
1387 | (cp_tree_c_tests): Rename to... | |
1388 | (cp_tree_cc_tests): ...this. | |
1389 | * pt.cc (cp_pt_c_tests): Rename to... | |
1390 | (cp_pt_cc_tests): ...this. | |
1391 | * tree.cc (cp_tree_c_tests): Rename to... | |
1392 | (cp_tree_cc_tests): ...this. | |
1393 | ||
1394 | 2022-01-19 Jason Merrill <jason@redhat.com> | |
1395 | ||
1396 | * parser.cc (saved_token_sentinel::rollback): Use | |
1397 | cp_lexer_previous_token. | |
1398 | ||
7a761ae6 GA |
1399 | 2022-01-18 Jakub Jelinek <jakub@redhat.com> |
1400 | ||
1401 | PR c++/104055 | |
1402 | * constexpr.cc (cxx_eval_outermost_constant_expr): If t is a | |
1403 | TARGET_EXPR with TARGET_EXPR_CLEANUP, use get_target_expr rather | |
1404 | than get_target_expr_sfinae with tf_no_cleanup, and don't set | |
1405 | TREE_CONSTANT. | |
1406 | ||
1407 | 2022-01-18 Jason Merrill <jason@redhat.com> | |
1408 | Jakub Jelinek <jakub@redhat.com> | |
1409 | ||
1410 | PR c++/104025 | |
1411 | * parser.cc (saved_token_sentinel::rollback): Call | |
1412 | cp_lexer_set_source_position. | |
1413 | (~saved_token_sentinel): Call rollback. | |
1414 | ||
1415 | 2022-01-18 Patrick Palka <ppalka@redhat.com> | |
1416 | ||
1417 | PR c++/104074 | |
1418 | * pt.cc (invalid_nontype_parm_type_p): Use WILDCARD_TYPE_P so | |
1419 | that we return false for DEPENDENT_OPERATOR_TYPE too. | |
1420 | ||
fc829782 GA |
1421 | 2022-01-17 Martin Liska <mliska@suse.cz> |
1422 | ||
1423 | * Make-lang.in: Rename .c names to .cc. | |
1424 | * config-lang.in: Likewise. | |
1425 | * constexpr.cc (cxx_eval_constant_expression): Likewise. | |
1426 | * coroutines.cc (morph_fn_to_coro): Likewise. | |
1427 | * cp-gimplify.cc (cp_gimplify_expr): Likewise. | |
1428 | * cp-lang.cc (struct lang_hooks): Likewise. | |
1429 | (get_template_argument_pack_elems_folded): Likewise. | |
1430 | * cp-objcp-common.cc (cp_tree_size): Likewise. | |
1431 | (cp_unit_size_without_reusable_padding): Likewise. | |
1432 | (pop_file_scope): Likewise. | |
1433 | (cp_pushdecl): Likewise. | |
1434 | * cp-objcp-common.h (GCC_CP_OBJCP_COMMON): Likewise. | |
1435 | (cxx_simulate_record_decl): Likewise. | |
1436 | * cp-tree.h (struct named_label_entry): Likewise. | |
1437 | (current_function_return_value): Likewise. | |
1438 | (more_aggr_init_expr_args_p): Likewise. | |
1439 | (get_function_version_dispatcher): Likewise. | |
1440 | (common_enclosing_class): Likewise. | |
1441 | (strip_fnptr_conv): Likewise. | |
1442 | (current_decl_namespace): Likewise. | |
1443 | (do_aggregate_paren_init): Likewise. | |
1444 | (cp_check_const_attributes): Likewise. | |
1445 | (qualified_name_lookup_error): Likewise. | |
1446 | (generic_targs_for): Likewise. | |
1447 | (mark_exp_read): Likewise. | |
1448 | (is_global_friend): Likewise. | |
1449 | (maybe_reject_flexarray_init): Likewise. | |
1450 | (module_token_lang): Likewise. | |
1451 | (handle_module_option): Likewise. | |
1452 | (literal_integer_zerop): Likewise. | |
1453 | (build_extra_args): Likewise. | |
1454 | (build_if_nonnull): Likewise. | |
1455 | (maybe_check_overriding_exception_spec): Likewise. | |
1456 | (finish_omp_target_clauses): Likewise. | |
1457 | (maybe_warn_zero_as_null_pointer_constant): Likewise. | |
1458 | (cxx_print_error_function): Likewise. | |
1459 | (decl_in_std_namespace_p): Likewise. | |
1460 | (merge_exception_specifiers): Likewise. | |
1461 | (mangle_module_global_init): Likewise. | |
1462 | (cxx_block_may_fallthru): Likewise. | |
1463 | (fold_builtin_source_location): Likewise. | |
1464 | (enum cp_oracle_request): Likewise. | |
1465 | (subsumes): Likewise. | |
1466 | (cp_finish_injected_record_type): Likewise. | |
1467 | (vtv_build_vtable_verify_fndecl): Likewise. | |
1468 | (cp_tree_c_finish_parsing): Likewise. | |
1469 | * cvt.cc (diagnose_ref_binding): Likewise. | |
1470 | (convert_to_void): Likewise. | |
1471 | (convert_force): Likewise. | |
1472 | (type_promotes_to): Likewise. | |
1473 | * decl.cc (make_unbound_class_template_raw): Likewise. | |
1474 | (cxx_init_decl_processing): Likewise. | |
1475 | (check_class_member_definition_namespace): Likewise. | |
1476 | (cxx_maybe_build_cleanup): Likewise. | |
1477 | * decl2.cc (maybe_emit_vtables): Likewise. | |
1478 | * error.cc (dump_function_name): Likewise. | |
1479 | * init.cc (is_class_type): Likewise. | |
1480 | (build_new_1): Likewise. | |
1481 | * lang-specs.h: Likewise. | |
1482 | * method.cc (make_alias_for_thunk): Likewise. | |
1483 | * module.cc (specialization_add): Likewise. | |
1484 | (module_state::read_cluster): Likewise. | |
1485 | * name-lookup.cc (check_extern_c_conflict): Likewise. | |
1486 | * name-lookup.h (struct cxx_binding): Likewise. | |
1487 | * parser.cc (cp_parser_identifier): Likewise. | |
1488 | * parser.h (struct cp_parser): Likewise. | |
1489 | * pt.cc (has_value_dependent_address): Likewise. | |
1490 | (push_tinst_level_loc): Likewise. | |
1491 | * semantics.cc (finish_omp_clauses): Likewise. | |
1492 | (finish_omp_atomic): Likewise. | |
1493 | * tree.cc (cp_save_expr): Likewise. | |
1494 | (cp_free_lang_data): Likewise. | |
1495 | * typeck.cc (cp_common_type): Likewise. | |
1496 | (strip_array_domain): Likewise. | |
1497 | (rationalize_conditional_expr): Likewise. | |
1498 | (check_return_expr): Likewise. | |
1499 | * vtable-class-hierarchy.cc: Likewise. | |
1500 | ||
1501 | 2022-01-17 Martin Liska <mliska@suse.cz> | |
1502 | ||
1503 | * call.c: Moved to... | |
1504 | * call.cc: ...here. | |
1505 | * class.c: Moved to... | |
1506 | * class.cc: ...here. | |
1507 | * constexpr.c: Moved to... | |
1508 | * constexpr.cc: ...here. | |
1509 | * cp-gimplify.c: Moved to... | |
1510 | * cp-gimplify.cc: ...here. | |
1511 | * cp-lang.c: Moved to... | |
1512 | * cp-lang.cc: ...here. | |
1513 | * cp-objcp-common.c: Moved to... | |
1514 | * cp-objcp-common.cc: ...here. | |
1515 | * cp-ubsan.c: Moved to... | |
1516 | * cp-ubsan.cc: ...here. | |
1517 | * cvt.c: Moved to... | |
1518 | * cvt.cc: ...here. | |
1519 | * cxx-pretty-print.c: Moved to... | |
1520 | * cxx-pretty-print.cc: ...here. | |
1521 | * decl.c: Moved to... | |
1522 | * decl.cc: ...here. | |
1523 | * decl2.c: Moved to... | |
1524 | * decl2.cc: ...here. | |
1525 | * dump.c: Moved to... | |
1526 | * dump.cc: ...here. | |
1527 | * error.c: Moved to... | |
1528 | * error.cc: ...here. | |
1529 | * except.c: Moved to... | |
1530 | * except.cc: ...here. | |
1531 | * expr.c: Moved to... | |
1532 | * expr.cc: ...here. | |
1533 | * friend.c: Moved to... | |
1534 | * friend.cc: ...here. | |
1535 | * g++spec.c: Moved to... | |
1536 | * g++spec.cc: ...here. | |
1537 | * init.c: Moved to... | |
1538 | * init.cc: ...here. | |
1539 | * lambda.c: Moved to... | |
1540 | * lambda.cc: ...here. | |
1541 | * lex.c: Moved to... | |
1542 | * lex.cc: ...here. | |
1543 | * mangle.c: Moved to... | |
1544 | * mangle.cc: ...here. | |
1545 | * method.c: Moved to... | |
1546 | * method.cc: ...here. | |
1547 | * name-lookup.c: Moved to... | |
1548 | * name-lookup.cc: ...here. | |
1549 | * optimize.c: Moved to... | |
1550 | * optimize.cc: ...here. | |
1551 | * parser.c: Moved to... | |
1552 | * parser.cc: ...here. | |
1553 | * pt.c: Moved to... | |
1554 | * pt.cc: ...here. | |
1555 | * ptree.c: Moved to... | |
1556 | * ptree.cc: ...here. | |
1557 | * rtti.c: Moved to... | |
1558 | * rtti.cc: ...here. | |
1559 | * search.c: Moved to... | |
1560 | * search.cc: ...here. | |
1561 | * semantics.c: Moved to... | |
1562 | * semantics.cc: ...here. | |
1563 | * tree.c: Moved to... | |
1564 | * tree.cc: ...here. | |
1565 | * typeck.c: Moved to... | |
1566 | * typeck.cc: ...here. | |
1567 | * typeck2.c: Moved to... | |
1568 | * typeck2.cc: ...here. | |
1569 | * vtable-class-hierarchy.c: Moved to... | |
1570 | * vtable-class-hierarchy.cc: ...here. | |
1571 | ||
1572 | 2022-01-17 Jakub Jelinek <jakub@redhat.com> | |
1573 | ||
1574 | PR c++/104031 | |
1575 | * cp-gimplify.c (cp_genericize_target_expr): Set DECL_CONTEXT of | |
1576 | TARGET_EXPR_SLOT to current_function_decl if it was NULL. | |
1577 | ||
1578 | 2022-01-17 Andrew Stubbs <ams@codesourcery.com> | |
1579 | ||
1580 | * parser.c (cp_parser_omp_requires): Don't "sorry" dynamic_allocators. | |
1581 | ||
617db51d GA |
1582 | 2022-01-14 Chung-Lin Tang <cltang@codesourcery.com> |
1583 | ||
1584 | PR c++/103705 | |
1585 | * semantics.c (finish_omp_clauses): Also continue peeling off of | |
1586 | outer node for ARRAY_REFs. | |
1587 | ||
1588 | 2022-01-14 Jakub Jelinek <jakub@redhat.com> | |
1589 | ||
1590 | PR c++/103991 | |
1591 | * cp-objcp-common.c (cxx_block_may_fallthru) <case IF_STMT>: For | |
1592 | IF_STMT_CONSTEXPR_P with constant false or true condition only | |
1593 | check if the taken clause may fall through. | |
1594 | * cp-gimplify.c (genericize_if_stmt): For consteval if, revert | |
1595 | to r12-5638^ behavior if then_ block can't fall through. For | |
1596 | constexpr if, revert to r12-5638^ behavior. | |
1597 | ||
ad3f0d08 GA |
1598 | 2022-01-13 Anthony Sharp <anthonysharp15@gmail.com> |
1599 | Jason Merrill <jason@redhat.com> | |
1600 | ||
1601 | PR c++/70417 | |
1602 | * parser.c (cp_parser_id_expression): Handle | |
1603 | -Wmissing-template-keyword. | |
1604 | (struct saved_token_sentinel): Add modes to control what happens | |
1605 | on destruction. | |
1606 | (cp_parser_statement): Adjust. | |
1607 | (cp_parser_skip_entire_template_parameter_list): New function that | |
1608 | skips an entire template parameter list. | |
1609 | (cp_parser_require_end_of_template_parameter_list): Rename old | |
1610 | cp_parser_skip_to_end_of_template_parameter_list. | |
1611 | (cp_parser_skip_to_end_of_template_parameter_list): Refactor to be | |
1612 | called from one of the above two functions. | |
1613 | (cp_parser_lambda_declarator_opt) | |
1614 | (cp_parser_explicit_template_declaration) | |
1615 | (cp_parser_enclosed_template_argument_list): Adjust. | |
1616 | ||
02a8a01b GA |
1617 | 2022-01-12 Jakub Jelinek <jakub@redhat.com> |
1618 | Jason Merrill <jason@redhat.com> | |
1619 | ||
1620 | PR c++/103480 | |
1621 | * tree.c (move): If expr is xvalue_p, just return expr without | |
1622 | build_static_cast. | |
1623 | ||
01a254e3 GA |
1624 | 2022-01-11 Jakub Jelinek <jakub@redhat.com> |
1625 | ||
1626 | PR c++/101597 | |
1627 | * class.c (build_vfn_ref): Build OBJ_TYPE_REF with INTEGER_CST | |
1628 | OBJ_TYPE_REF_TOKEN with type equal to OBJ_TYPE_REF_OBJECT type. | |
1629 | * error.c (resolve_virtual_fun_from_obj_type_ref): Use type of | |
1630 | OBJ_TYPE_REF_TOKEN rather than type of OBJ_TYPE_REF_OBJECT as | |
1631 | obj_type. | |
1632 | ||
1633 | 2022-01-11 Patrick Palka <ppalka@redhat.com> | |
1634 | ||
1635 | PR c++/103831 | |
1636 | * call.c (build_new_method_call): Consider dependent bases only | |
1637 | if 'this' is available. | |
1638 | ||
1639 | 2022-01-11 Olivier Hainque <hainque@adacore.com> | |
1640 | ||
1641 | * decl.c (cxx_init_decl_processing): Move code possibly | |
1642 | altering flag_weak before code testing it. | |
1643 | ||
d9450aa0 GA |
1644 | 2022-01-10 Patrick Palka <ppalka@redhat.com> |
1645 | ||
1646 | PR c++/103879 | |
1647 | * constexpr.c (cxx_fold_indirect_ref): Split out object/offset | |
1648 | canonicalization step into a local lambda. Strengthen it to | |
1649 | absorb more components at position 0. Use it before both calls | |
1650 | to cxx_fold_indirect_ref_1. | |
1651 | ||
1652 | 2022-01-10 Patrick Palka <ppalka@redhat.com> | |
1653 | ||
1654 | PR c++/103783 | |
1655 | * call.c (cand_parms_match): Skip over 'this' when given one | |
1656 | static and one non-static member function. | |
1657 | ||
1658 | 2022-01-10 Jakub Jelinek <jakub@redhat.com> | |
1659 | ||
1660 | PR c++/103912 | |
1661 | * semantics.c (expand_or_defer_fn): For immediate functions, set | |
1662 | node->body_removed to true and clear analyzed, definition and | |
1663 | force_output. | |
1664 | * decl2.c (c_parse_final_cleanups): Ignore immediate functions for | |
1665 | expand_or_defer_fn. | |
1666 | ||
2848ef14 GA |
1667 | 2022-01-08 Jakub Jelinek <jakub@redhat.com> |
1668 | ||
1669 | PR c++/89074 | |
1670 | * constexpr.c (cxx_maybe_fold_addr_pointer_plus): New function. | |
1671 | (cxx_eval_binary_expression): Use it. | |
1672 | ||
1673 | 2022-01-08 Jason Merrill <jason@redhat.com> | |
1674 | ||
1675 | PR c++/103946 | |
1676 | * init.c (build_vec_init): Remove assert. | |
1677 | * tree.c (build_vec_init_expr): Likewise. | |
1678 | ||
1679 | 2022-01-08 Jason Merrill <jason@redhat.com> | |
1680 | ||
1681 | PR c++/100588 | |
1682 | * call.c (build_op_delete_call): Ignore destroying delete | |
1683 | if alloc_fn. | |
1684 | ||
55e96bf9 GA |
1685 | 2022-01-07 Jason Merrill <jason@redhat.com> |
1686 | ||
1687 | PR c++/20040 | |
1688 | * init.c (build_new_1): Also build pointer cleanup if | |
1689 | TYPE_GETS_DELETE. | |
1690 | * cp-tree.h (TYPE_GETS_VEC_DELETE): New. | |
1691 | ||
1692 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1693 | ||
1694 | PR c++/103936 | |
1695 | PR c++/65591 | |
1696 | * cp-gimplify.c (cp_gimplify_expr): Restore VEC_INIT_EXPR handling. | |
1697 | ||
1698 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1699 | ||
1700 | PR c++/103711 | |
1701 | * init.c (perform_target_ctor): Select destructor by in_chrg. | |
1702 | ||
1703 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1704 | ||
1705 | PR c++/61611 | |
1706 | * except.c (in_nested_catch): New. | |
1707 | (expand_end_catch_block): Check it. | |
1708 | ||
1709 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1710 | ||
1711 | PR c++/33799 | |
1712 | PR c++/102191 | |
1713 | * except.c (maybe_splice_retval_cleanup): Check | |
1714 | current_binding_level. | |
1715 | * semantics.c (do_poplevel): Call it here. | |
1716 | * parser.c (cp_parser_compound_statement): Not here. | |
1717 | ||
1718 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1719 | ||
1720 | PR c++/53868 | |
1721 | * decl.c (cp_finish_decl): Use wrap_temporary_cleanups for | |
1722 | cleanups from set_up_extended_ref_temp. | |
1723 | (wrap_temporary_cleanups): Ignore array cleanups. | |
1724 | (initialize_local_var): Don't check for array here. | |
1725 | * cp-tree.h (BIND_EXPR_VEC_DTOR): New. | |
1726 | * init.c (build_vec_delete_1): Set it. | |
1727 | ||
1728 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1729 | ||
1730 | PR c++/66451 | |
1731 | * init.c (build_vec_delete_1): Handle throwing dtor. | |
1732 | (build_vec_init): Tell it we're in a cleanup already. | |
1733 | ||
1734 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1735 | ||
1736 | * typeck2.c (split_nonconstant_init_1): Don't cleanup the last elt. | |
1737 | (split_nonconstant_init): Adjust. | |
1738 | ||
1739 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1740 | ||
1741 | PR c++/66139 | |
1742 | PR c++/52320 | |
1743 | * constexpr.c (replace_decl): Rename from replace_result_decl. | |
1744 | * cp-tree.h (replace_decl): Declare it. | |
1745 | * cp-gimplify.c (cp_gimplify_init_expr): Call it. | |
1746 | (cp_gimplify_expr): Don't handle VEC_INIT_EXPR. | |
1747 | (cp_genericize_init, cp_genericize_init_expr) | |
1748 | (cp_genericize_target_expr): New. | |
1749 | (cp_fold_r): Call them. | |
1750 | * tree.c (build_array_copy): Add a TARGET_EXPR. | |
1751 | * typeck2.c (digest_init_r): Look through a TARGET_EXPR. | |
1752 | ||
1753 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1754 | ||
1755 | PR c++/94041 | |
1756 | * decl.c (initialize_local_var): Fix comment. | |
1757 | * init.c (build_new_1): Do stabilize array init. | |
1758 | (build_vec_init): Use TARGET_EXPR for cleanup. Initialization | |
1759 | of an element from an explicit initializer is not a | |
1760 | full-expression. | |
1761 | * tree.c (expand_vec_init_expr): Pass flags through. | |
1762 | * typeck2.c (split_nonconstant_init_1): Handle VEC_INIT_EXPR. | |
1763 | (split_nonconstant_init): Handle array cleanups. | |
1764 | * cp-tree.h: Adjust. | |
1765 | ||
1766 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1767 | ||
1768 | PR c++/94041 | |
1769 | * decl.c (check_initializer): Remove obsolete comment. | |
1770 | (wrap_cleanups_r): Don't wrap CLEANUP_EH_ONLY. | |
1771 | (initialize_local_var): Change assert to test. | |
1772 | * typeck2.c (maybe_push_temp_cleanup): New. | |
1773 | (split_nonconstant_init_1): Use it. | |
1774 | (split_nonconstant_init): Clear cleanup flags. | |
1775 | ||
1776 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1777 | ||
1778 | PR c++/92385 | |
1779 | * typeck2.c (PICFLAG_VEC_INIT): New. | |
1780 | (process_init_constructor_array): Set it. | |
1781 | (process_init_constructor): Handle it. | |
1782 | (split_nonconstant_init_1): Handle VEC_INIT_EXPR. | |
1783 | * init.c (build_vec_init): Likewise. | |
1784 | * cp-gimplify.c (cp_gimplify_expr): Factor out... | |
1785 | * tree.c (expand_vec_init_expr): ...this function. | |
1786 | (build_vec_init_elt): Handle BRACE_ENCLOSED_INITIALIZER_P. | |
1787 | (build_vec_init_expr): Likewise. | |
1788 | * constexpr.c (cxx_eval_vec_init): Likewise. | |
1789 | (reduced_constant_expression_p): Check arrays before C++20. | |
1790 | * cp-tree.h (expand_vec_init_expr): Declare. | |
1791 | ||
1792 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1793 | ||
1794 | * init.c (build_new_1): Remove preevaluation code. | |
1795 | ||
0fbefa25 GA |
1796 | 2022-01-05 Nathan Sidwell <nathan@acm.org> |
1797 | ||
1798 | * pt.c (instantiate_class_template_1): Process attribute((used)) set | |
1799 | in class's context. | |
1800 | ||
1801 | 2022-01-05 Nathan Sidwell <nathan@acm.org> | |
1802 | ||
1803 | * init.c (build_new_1): Check complain before alignment warning. | |
1804 | ||
7d11b64b GA |
1805 | 2022-01-04 Jason Merrill <jason@redhat.com> |
1806 | ||
1807 | * cp-tree.h (class releasing_vec): Add begin/end fns. | |
1808 | ||
1809 | 2022-01-04 Jason Merrill <jason@redhat.com> | |
1810 | ||
1811 | * init.c: Include -*- C++ -*- on first line. | |
1812 | ||
a4ae8c37 GA |
1813 | 2022-01-03 Marek Polacek <polacek@redhat.com> |
1814 | ||
1815 | PR c++/103758 | |
1816 | * parser.c (cp_parser_decl_specifier_seq): Replace %<decl-specifier%> | |
1817 | with %qD. | |
1818 | ||
1819 | 2022-01-03 Marek Polacek <polacek@redhat.com> | |
1820 | ||
1821 | * parser.c (make_char_string_pack): Add a cast to const unsigned | |
1822 | char *. | |
1823 | ||
1824 | 2022-01-03 Jakub Jelinek <jakub@redhat.com> | |
1825 | ||
1826 | PR c++/103600 | |
1827 | * rtti.c (get_tinfo_decl_direct): Add "non overlapping" attribute | |
1828 | to DECL_TINFO_P VAR_DECLs. | |
1829 | ||
5da23a13 GA |
1830 | 2022-01-02 Jason Merrill <jason@redhat.com> |
1831 | ||
1832 | * init.c (build_vec_init): Append the decrement to elt_init. | |
1833 | ||
1834 | 2022-01-02 Jason Merrill <jason@redhat.com> | |
1835 | ||
1836 | * decl.c (wrap_cleanups_r): Don't wrap if noexcept. | |
1837 | ||
ad41bd84 | 1838 | \f |
6123f29a | 1839 | Copyright (C) 2022 Free Software Foundation, Inc. |
ad41bd84 JM |
1840 | |
1841 | Copying and distribution of this file, with or without modification, | |
1842 | are permitted in any medium without royalty provided the copyright | |
1843 | notice and this notice are preserved. |