]>
Commit | Line | Data |
---|---|---|
510613e7 GA |
1 | 2022-03-14 Jakub Jelinek <jakub@redhat.com> |
2 | ||
3 | PR tree-optimization/102586 | |
4 | * call.cc (build_cxx_call): Diagnose __builtin_clear_padding where | |
5 | first argument's type is pointer to non-trivially-copyable type unless | |
6 | it is address of a variable or parameter. | |
7 | ||
57eeedda GA |
8 | 2022-03-12 Patrick Palka <ppalka@redhat.com> |
9 | ||
10 | PR c++/104641 | |
11 | * cp-tree.h (tsubst_flags::tf_tst_ok): New flag. | |
12 | * decl.cc (make_typename_type): Allow a typename-specifier to | |
13 | resolve to a template when tf_tst_ok, in which case return | |
14 | a CTAD placeholder for the template. | |
15 | * pt.cc (tsubst_decl) <case VAR_DECL>: Set tf_tst_ok when | |
16 | substituting the type. | |
17 | (tsubst): Clear tf_tst_ok and remember if it was set. | |
18 | <case TYPENAME_TYPE>: Pass tf_tst_ok to make_typename_type | |
19 | appropriately. | |
20 | (tsubst_copy) <case CAST_EXPR>: Set tf_tst_ok when substituting | |
21 | the type. | |
22 | (tsubst_copy_and_build) <case CAST_EXPR>: Likewise. | |
23 | <case CONSTRUCTOR>: Likewise. | |
24 | ||
25 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
26 | ||
27 | PR c++/104622 | |
28 | * call.cc (missing_conversion_p): Define. | |
29 | (add_candidates): Use it. | |
30 | * pt.cc (check_non_deducible_conversion): Change type of strict | |
31 | parameter to unification_kind_t and directly test for DEDUCE_CALL. | |
32 | ||
33 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
34 | ||
35 | PR c++/104527 | |
36 | * constraint.cc (normalize_atom): Set | |
37 | ATOMIC_CONSTR_EXPR_FROM_CONCEPT_P appropriately. | |
38 | (get_mapped_args): Make static, adjust parameters. Always | |
39 | return a vector whose depth corresponds to the template depth of | |
40 | the context of the atomic constraint expression. Micro-optimize | |
41 | by passing false as exact to safe_grow_cleared and by collapsing | |
42 | a multi-level depth-one argument vector. | |
43 | (satisfy_atom): Adjust call to get_mapped_args and | |
44 | diagnose_atomic_constraint. | |
45 | (diagnose_atomic_constraint): Replace map parameter with an args | |
46 | parameter. | |
47 | * cp-tree.h (ATOMIC_CONSTR_EXPR_FROM_CONCEPT_P): Define. | |
48 | (get_mapped_args): Remove declaration. | |
49 | ||
50 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
51 | Jason Merrill <jason@redhat.com> | |
52 | ||
53 | PR c++/98644 | |
54 | * constexpr.cc (mark_non_constant): Define, split out from ... | |
55 | (cxx_eval_outermost_constant_expr): ... here. | |
56 | (maybe_constant_value): Use it. | |
57 | ||
58 | 2022-03-12 Patrick Palka <ppalka@redhat.com> | |
59 | ||
60 | * semantics.cc (finish_unary_fold_expr): Use input_location | |
61 | instead of UNKNOWN_LOCATION. | |
62 | (finish_binary_fold_expr): Likewise. | |
63 | ||
64 | 2022-03-12 Thomas Schwinge <thomas@codesourcery.com> | |
65 | ||
66 | PR other/65095 | |
67 | * semantics.cc (handle_omp_array_sections_1) | |
68 | (cp_oacc_check_attachments): Call 'user_omp_clause_code_name' | |
69 | instead of 'c_omp_map_clause_name'. | |
70 | ||
5e28be89 GA |
71 | 2022-03-10 Marek Polacek <polacek@redhat.com> |
72 | ||
73 | PR c++/104608 | |
74 | * parser.cc (cp_parser_template_name): Repeat lookup of | |
75 | TYPE_DECLs. | |
76 | ||
77 | 2022-03-10 Marek Polacek <polacek@redhat.com> | |
78 | ||
79 | PR c++/104752 | |
80 | * semantics.cc (finish_compound_literal): Disallow auto{x} for | |
81 | is_constrained_auto. | |
82 | * typeck2.cc (build_functional_cast_1): Likewise. | |
83 | ||
84 | 2022-03-10 Marek Polacek <polacek@redhat.com> | |
85 | ||
86 | PR c++/104846 | |
87 | * decl.cc (grokdeclarator): Check FUNC_OR_METHOD_TYPE_P before giving | |
88 | data member errors. | |
89 | ||
90 | 2022-03-10 Jakub Jelinek <jakub@redhat.com> | |
91 | ||
92 | PR c++/103460 | |
93 | * decl.cc (grok_op_properties): Allow variadic operator[] for | |
94 | C++23. | |
95 | ||
96 | 2022-03-10 Roger Sayle <roger@nextmovesoftware.com> | |
97 | ||
98 | PR c++/95999 | |
99 | * decl.cc (finish_enum_value_list): If VALUE isn't an INTEGER_CST | |
100 | consider it to be zero (i.e. treat it like error_mark_node). | |
101 | (build_enumerator): Likewise, if PREV_VALUE isn't an INTEGER_CST, | |
102 | set VALUE to error_mark_node. | |
103 | ||
104 | 2022-03-10 Roger Sayle <roger@nextmovesoftware.com> | |
105 | ||
106 | PR c++/39751 | |
107 | * parser.cc (cp_parser_late_parsing_for_member): Confirm the token | |
108 | stream hasn't been purged before processing DECL_PENDING_INLINE. | |
109 | ||
8cc4f9cd GA |
110 | 2022-03-09 Patrick Palka <ppalka@redhat.com> |
111 | ||
112 | PR c++/104823 | |
113 | * except.cc (build_noexcept_spec): Strengthen dependence check | |
114 | to instantiation_dependent_expression_p. | |
115 | * parser.cc (cp_parser_parenthesized_expression_list_elt): | |
116 | Remove fold_expr_p parameter, and don't call | |
117 | instantiate_non_dependent_expr. | |
118 | (cp_parser_parenthesized_expression_list): Adjust accordingly. | |
119 | * pt.cc (expand_integer_pack): Strengthen dependence check | |
120 | to instantiation_dependent_expression_p. | |
121 | (instantiate_non_dependent_expr_internal): Adjust comment. | |
122 | (instantiate_non_dependent_expr_sfinae): Likewise. Drop | |
123 | the potentially-constant check, and relax and turn the | |
124 | dependence check into a checking assert. | |
125 | (instantiate_non_dependent_or_null): Adjust comment. | |
126 | * semantics.cc (finish_decltype_type): Keep | |
127 | processing_template_decl cleared after calling | |
128 | instantiate_non_dependent_expr_sfinae. | |
129 | ||
130 | 2022-03-09 Patrick Palka <ppalka@redhat.com> | |
131 | ||
132 | PR c++/102137 | |
133 | PR c++/87820 | |
134 | * cp-tree.h (is_copy_initialization): Declare. | |
135 | * decl.cc (cp_finish_decl): Set LOOKUP_ONLYCONVERTING | |
136 | when is_copy_initialization is true. | |
137 | * init.cc (build_aggr_init): Split out copy-initialization | |
138 | check into ... | |
139 | (is_copy_initialization): ... here. | |
140 | * pt.cc (instantiate_decl): Pass 0 instead of | |
141 | LOOKUP_ONLYCONVERTING as flags to cp_finish_decl. | |
142 | ||
143 | 2022-03-09 Patrick Palka <ppalka@redhat.com> | |
144 | ||
145 | PR c++/65396 | |
146 | * cp-tree.h (merge_default_template_args): Declare. | |
147 | * decl.cc (merge_default_template_args): Define, factored out | |
148 | from redeclare_class_template. | |
149 | (duplicate_decls): Use it when merging member function template | |
150 | and free function declarations. | |
151 | * pt.cc (redeclare_class_template): Factor out default argument | |
152 | merging logic into merge_default_template_args. Improve location | |
153 | of a note when there's a template parameter kind mismatch. | |
154 | ||
155 | 2022-03-09 Jakub Jelinek <jakub@redhat.com> | |
156 | ||
157 | PR c/104711 | |
158 | * constexpr.cc (cxx_eval_check_shift_p): Use TYPE_OVERFLOW_WRAPS | |
159 | instead of TYPE_UNSIGNED. | |
160 | * typeck.cc (cp_build_binary_op): Don't emit | |
161 | -Wshift-negative-value warning if TYPE_OVERFLOW_WRAPS. | |
162 | ||
8d038a84 GA |
163 | 2022-03-08 Roger Sayle <roger@nextmovesoftware.com> |
164 | ||
165 | PR c++/96440 | |
166 | * decl.cc (start_decl): Defend against prefix_attributes being | |
167 | error_mark_node. | |
168 | ||
169 | 2022-03-08 Roger Sayle <roger@nextmovesoftware.com> | |
170 | ||
171 | PR c++/96437 | |
172 | * parser.cc (synthesize_implicit_template_parm): Check that | |
173 | TREE_VALUE (new_parm) isn't error_mark_node before setting its | |
174 | DECL_VIRTUAL_P. | |
175 | ||
176 | 2022-03-08 Roger Sayle <roger@nextmovesoftware.com> | |
177 | ||
178 | PR c++/96329 | |
179 | * parser.cc (cp_parser_linkage_specification): Treat the case where | |
180 | linkage is error_mark_node as "invalid linkage-specification". | |
181 | ||
182 | 2022-03-08 Marek Polacek <polacek@redhat.com> | |
183 | ||
184 | PR c++/104108 | |
185 | * pt.cc (convert_nontype_argument): Recompute | |
186 | value_dependent_expression_p after build_converted_constant_expr. | |
187 | ||
188 | 2022-03-08 Marek Polacek <polacek@redhat.com> | |
189 | ||
190 | * decl2.cc (is_late_template_attribute): Do not defer attribute | |
191 | unavailable. | |
192 | * pt.cc (tsubst_enum): Set TREE_UNAVAILABLE. | |
193 | ||
194 | 2022-03-08 Jakub Jelinek <jakub@redhat.com> | |
195 | ||
196 | PR c++/104806 | |
197 | * search.cc (lookup_field_fuzzy_info::fuzzy_lookup_field): Ignore | |
198 | identifiers with space at the end. | |
199 | ||
e6533e2e GA |
200 | 2022-03-07 Jason Merrill <jason@redhat.com> |
201 | ||
202 | PR c++/104618 | |
203 | * decl2.cc (mark_single_function): Look through parens and location | |
204 | wrapper. | |
205 | * typeck.cc (cp_build_addr_expr_1): Not here. | |
206 | ||
207 | 2022-03-07 Jakub Jelinek <jakub@redhat.com> | |
208 | ||
209 | * parser.cc (cp_parser_omp_clause_map): Add missing space in string | |
210 | literal. | |
211 | ||
212 | 2022-03-07 Jakub Jelinek <jakub@redhat.com> | |
213 | ||
214 | * cvt.cc: Fix up duplicated word issue in a comment. | |
215 | * pt.cc: Likewise. | |
216 | * module.cc: Likewise. | |
217 | * coroutines.cc: Likewise. | |
218 | ||
8d96e14c GA |
219 | 2022-03-04 Nathan Sidwell <nathan@acm.org> |
220 | ||
221 | * mangle.cc (is_std_substitution): Check global module. | |
222 | (is_std_substitution_char): Return bool. | |
223 | ||
224 | 2022-03-04 Nathan Sidwell <nathan@acm.org> | |
225 | ||
226 | * cp-tree.h (mangle_identifier): Replace with ... | |
227 | (mangle_module_component): ... this. | |
228 | * mangle.cc (dump_substitution_candidates): Adjust. | |
229 | (add_substitution): Likewise. | |
230 | (find_substitution): Likewise. | |
231 | (unmangled_name_p): Likewise. | |
232 | (mangle_module_substitution): Reimplement. | |
233 | (mangle_module_component): New. | |
234 | (write_module, maybe_write_module): Adjust. | |
235 | (write_name): Drop modules here. | |
236 | (write_unqualified): Do them here instead. | |
237 | (mangle_global_init): Adjust. | |
238 | * module.cc (module_state::mangle): Adjust. | |
239 | (mangle_module): Likewise. | |
240 | (get_originating_module): Adjust. | |
241 | ||
a35f1697 GA |
242 | 2022-02-28 Marek Polacek <polacek@redhat.com> |
243 | ||
244 | PR c++/104682 | |
245 | * cp-tree.h (build_enumerator): Adjust. | |
246 | * decl.cc (finish_enum): Make it return the new decl. | |
247 | * pt.cc (tsubst_enum): Propagate TREE_DEPRECATED and TREE_UNAVAILABLE. | |
248 | ||
249 | 2022-02-28 Marek Polacek <polacek@redhat.com> | |
250 | ||
251 | PR c++/104667 | |
252 | * decl2.cc (is_late_template_attribute): Cope with a decl without | |
253 | a type. | |
254 | ||
88c1b038 GA |
255 | 2022-02-27 Jason Merrill <jason@redhat.com> |
256 | ||
257 | PR c++/104618 | |
258 | * typeck.cc (cp_build_addr_expr_1): Also | |
259 | maybe_undo_parenthesized_ref. | |
260 | ||
756a6185 GA |
261 | 2022-02-24 Martin Liska <mliska@suse.cz> |
262 | ||
263 | * pt.cc (defarg_insts_for): Use braces for subobject. | |
264 | ||
5a9ba3f2 GA |
265 | 2022-02-18 Patrick Palka <ppalka@redhat.com> |
266 | ||
267 | PR c++/94944 | |
268 | * pt.cc (maybe_instantiate_noexcept): For non-static member | |
269 | functions, set current_class_ptr/ref to the specialized 'this' | |
270 | instead. | |
271 | ||
0bdb0498 GA |
272 | 2022-02-17 Jason Merrill <jason@redhat.com> |
273 | ||
274 | PR c++/104539 | |
275 | * pt.cc (mark_decl_instantiated): Don't clear DECL_COMDAT. | |
276 | ||
277 | 2022-02-17 Jason Merrill <jason@redhat.com> | |
278 | ||
279 | PR c++/90451 | |
280 | * decl2.cc (mark_single_function): New. | |
281 | * cp-tree.h: Declare it. | |
282 | * typeck.cc (cp_build_addr_expr_1): mark_used when making a PMF. | |
283 | * semantics.cc (finish_qualified_id_expr): Not here. | |
284 | (finish_id_expression_1): Or here. | |
285 | (finish_decltype_type): Call mark_single_function. | |
286 | * cvt.cc (convert_to_void): And here. | |
287 | * pt.cc (convert_nontype_argument): And here. | |
288 | * init.cc (build_offset_ref): Adjust assert. | |
289 | ||
290 | 2022-02-17 Patrick Palka <ppalka@redhat.com> | |
291 | ||
292 | PR c++/104565 | |
293 | * semantics.cc (finish_compound_literal): Don't perform | |
294 | non-dependent expr folding before calling check_narrowing. | |
295 | ||
cb3afcd2 GA |
296 | 2022-02-16 Patrick Palka <ppalka@redhat.com> |
297 | ||
298 | PR c++/104507 | |
299 | * constexpr.cc (potential_constant_expression_1) | |
300 | <case NON_DEPENDENT_EXPR>: Return false instead of recursing. | |
301 | Assert tf_error isn't set. | |
302 | ||
875e493b GA |
303 | 2022-02-15 Jason Merrill <jason@redhat.com> |
304 | ||
305 | PR c++/104107 | |
306 | PR c++/95036 | |
307 | * pt.cc (coerce_template_template_parms): Take full parms. | |
308 | Avoid adding too much of outer_args. | |
309 | (coerce_template_template_parm): Adjust. | |
310 | (template_template_parm_bindings_ok_p): Adjust. | |
311 | (convert_template_argument): Adjust. | |
312 | ||
1f8a09d2 GA |
313 | 2022-02-14 Jakub Jelinek <jakub@redhat.com> |
314 | ||
315 | PR c++/104513 | |
316 | * constexpr.cc (potential_constant_expression_1) <case GOTO_EXPR>: | |
317 | Don't punt if returns (target). | |
318 | ||
e8d68f0a GA |
319 | 2022-02-11 Jakub Jelinek <jakub@redhat.com> |
320 | ||
321 | PR c++/104472 | |
322 | * constexpr.cc (cxx_eval_internal_function) <case IFN_VEC_CONVERT>: | |
323 | Only return fold_const_call result if it is non-NULL. Otherwise | |
324 | fall through into the default: case to return t, set *non_constant_p | |
325 | and emit diagnostics if needed. | |
326 | ||
a645583d GA |
327 | 2022-02-10 Jason Merrill <jason@redhat.com> |
328 | ||
329 | * module.cc (depset::hash::add_specializations): Use | |
330 | STRIP_TEMPLATE. | |
331 | ||
332 | 2022-02-10 Tobias Burnus <tobias@codesourcery.com> | |
333 | ||
334 | PR c++/102204 | |
335 | * decl2.cc (cp_omp_mappable_type_1): Remove check for virtual | |
336 | members as those are permitted since OpenMP 5.0. | |
337 | ||
338 | 2022-02-10 Patrick Palka <ppalka@redhat.com> | |
339 | ||
340 | * pt.cc (filter_memfn_lookup): Handle dependent USING_DECL | |
341 | better. | |
342 | ||
343 | 2022-02-10 Marcel Vollweiler <marcel@codesourcery.com> | |
344 | ||
345 | * parser.cc (cp_parser_omp_clause_name): Parse 'has_device_addr' clause. | |
346 | (cp_parser_omp_var_list_no_open): Handle array sections. | |
347 | (cp_parser_omp_all_clauses): Added PRAGMA_OMP_CLAUSE_HAS_DEVICE_ADDR | |
348 | case. | |
349 | (cp_parser_omp_target_update): Added HAS_DEVICE_ADDR to OMP_CLAUSE_MASK. | |
350 | * semantics.cc (handle_omp_array_sections): Handle clause restrictions. | |
351 | (finish_omp_clauses): Handle array sections. | |
352 | ||
3adf509f GA |
353 | 2022-02-09 Patrick Palka <ppalka@redhat.com> |
354 | ||
355 | PR c++/104432 | |
356 | * call.cc (build_new_method_call): When a non-dependent call | |
357 | resolves to a specialization of a member template, always build | |
358 | the pruned overload set using the member template, not the | |
359 | specialization. | |
360 | * pt.cc (filter_memfn_lookup): New parameter newtype. Simplify | |
361 | and correct how members from the new lookup set are matched to | |
362 | those from the old one. | |
363 | (tsubst_baselink): Pass binfo_type as newtype to | |
364 | filter_memfn_lookup. | |
365 | ||
366 | 2022-02-09 Jason Merrill <jason@redhat.com> | |
367 | ||
368 | PR c++/103752 | |
369 | * module.cc (trees_out::core_vals): Stream explicit specifier. | |
370 | (trees_in::core_vals): Likewise. | |
371 | * pt.cc (store_explicit_specifier): No longer static. | |
372 | (tsubst_function_decl): Clear DECL_HAS_DEPENDENT_EXPLICIT_SPEC_P. | |
373 | * cp-tree.h (lookup_explicit_specifier): Declare. | |
374 | ||
375 | 2022-02-09 Jason Merrill <jason@redhat.com> | |
376 | ||
377 | PR c++/96876 | |
378 | * typeck2.cc (split_nonconstant_init_1): Push cleanups for | |
379 | preceding members with constant initialization. | |
380 | (maybe_push_temp_cleanup): Do nothing if -fno-exceptions. | |
381 | ||
2a2fda2d GA |
382 | 2022-02-08 Jakub Jelinek <jakub@redhat.com> |
383 | ||
384 | PR c++/104379 | |
385 | * name-lookup.cc (check_local_shadow): When diagnosing shadowing | |
386 | of a member or global declaration, add warning suppression for | |
387 | the decl and don't warn again on it. | |
388 | ||
389 | 2022-02-08 Jakub Jelinek <jakub@redhat.com> | |
390 | ||
391 | PR c++/104403 | |
392 | * constexpr.cc (cxx_eval_constant_expression): Don't assert DECL_EXPRs | |
393 | of TREE_STATIC vars may only appear in -std=c++23. | |
394 | ||
395 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
396 | ||
397 | PR c++/80951 | |
398 | * pt.cc (uses_deducible_template_parms): Consider the | |
399 | noexcept-spec of a function type. | |
400 | ||
401 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
402 | ||
403 | PR c++/104410 | |
404 | * constraint.cc (satisfaction_value): Relax assert to accept | |
405 | cv-qualified bool. | |
406 | ||
407 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
408 | ||
409 | PR c++/103706 | |
410 | * pt.cc (preserve_args): New function. | |
411 | (tsubst_lambda_expr): Use it when setting LAMBDA_EXPR_REGEN_INFO. | |
412 | ||
413 | 2022-02-08 Patrick Palka <ppalka@redhat.com> | |
414 | ||
415 | PR c++/103706 | |
416 | * constraint.cc (satisfy_declaration_constraints): Use | |
417 | lambda_regenerating_args instead. | |
418 | * cp-tree.h (lambda_regenerating_args): Declare. | |
419 | * pt.cc (lambda_regenerating_args): Define, split out from | |
420 | satisfy_declaration_constraints. | |
421 | (do_auto_deduction): Use lambda_regenerating_args to obtain the | |
422 | full set of outer template arguments for satisfaction when | |
423 | inside a lambda. | |
424 | ||
353f8fcc GA |
425 | 2022-02-06 Patrick Palka <ppalka@redhat.com> |
426 | ||
427 | PR c++/96242 | |
428 | * decl2.cc (mark_used): Directly synthesize a DECL_MAYBE_DELETED | |
429 | fn by calling maybe_synthesize_method instead of relying on | |
430 | maybe_instantiate_noexcept. Move call to m_i_n after the | |
431 | DECL_DELETED_FN handling. | |
432 | * pt.cc (maybe_instantiate_noexcept): Restrict DECL_MAYBE_DELETED | |
433 | fn synthesis to only those with an implicit noexcept-spec, and | |
434 | return !DECL_DELETED_FN instead of !DECL_MAYBE_DELETED afterwards. | |
435 | ||
436 | 2022-02-06 Jakub Jelinek <jakub@redhat.com> | |
437 | ||
438 | PR c++/89074 | |
439 | PR c++/104033 | |
440 | * constexpr.cc (cxx_eval_binary_expression): Temporarily set | |
441 | folding_cxx_constexpr. | |
442 | ||
661109b0 GA |
443 | 2022-02-05 Jason Merrill <jason@redhat.com> |
444 | ||
445 | PR c++/104300 | |
446 | PR c++/92385 | |
447 | * cp-tree.h (get_vec_init_expr): New. | |
448 | (target_expr_needs_replace): New. | |
449 | * cp-gimplify.cc (cp_gimplify_init_expr): Use it. | |
450 | (struct cp_fold_data): New. | |
451 | (cp_fold_r): Only genericize inits at end of fn. | |
452 | (cp_fold_function): Here. | |
453 | (cp_fully_fold_init): Not here. | |
454 | * init.cc (build_vec_init): Use get_vec_init_expr. | |
455 | * tree.cc (build_vec_init_expr): Likewise. | |
456 | * typeck2.cc (split_nonconstant_init_1): Likewise. | |
457 | (process_init_constructor): Wrap VEC_INIT_EXPR in | |
458 | TARGET_EXPR. | |
459 | ||
460 | 2022-02-05 Jason Merrill <jason@redhat.com> | |
461 | ||
462 | * pt.cc (iterative_hash_template_arg): Add comment. | |
463 | ||
682ede39 GA |
464 | 2022-02-03 Patrick Palka <ppalka@redhat.com> |
465 | ||
466 | PR c++/104079 | |
467 | * pt.cc (value_dependent_noexcept_spec_p): New predicate split | |
468 | out from ... | |
469 | (dependent_type_p_r): ... here. | |
470 | (instantiation_dependent_r): Use value_dependent_noexcept_spec_p | |
471 | to consider dependence of a noexcept-spec before C++17. | |
472 | * tree.cc (fixup_deferred_exception_variants): Clear | |
473 | TYPE_DEPENDENT_P_VALID. | |
474 | ||
475 | 2022-02-03 Jason Merrill <jason@redhat.com> | |
476 | ||
477 | PR c++/104302 | |
478 | * decl.cc (maybe_deduce_size_from_array_init): Give up | |
479 | on type-dependent init. | |
480 | (cp_complete_array_type): Only call reshape_init for character | |
481 | array. | |
482 | ||
ae7e4af9 GA |
483 | 2022-02-01 Jason Merrill <jason@redhat.com> |
484 | ||
485 | PR c++/103186 | |
486 | * pt.cc (defarg_inst): Use tree_vec_map_cache_hasher. | |
487 | (defarg_insts_for): New. | |
488 | (tsubst_default_argument): Adjust. | |
489 | ||
1bb52662 GA |
490 | 2022-01-31 Marek Polacek <polacek@redhat.com> |
491 | ||
492 | PR c++/102414 | |
493 | PR c++/101874 | |
494 | * decl.cc (create_array_type_for_decl): Use template_placeholder_p. | |
495 | Sorry on a variable-length array of auto. | |
496 | ||
497 | 2022-01-31 Marek Polacek <polacek@redhat.com> | |
498 | ||
499 | PR c++/102434 | |
500 | * class.cc (finish_struct): Don't allow union initializer_list. | |
501 | ||
502 | 2022-01-31 Patrick Palka <ppalka@redhat.com> | |
503 | ||
504 | PR c++/104294 | |
505 | * pt.cc (ctor_deduction_guides_for): Correct computation of | |
506 | outer_args. | |
507 | ||
508 | 2022-01-31 Patrick Palka <ppalka@redhat.com> | |
509 | ||
510 | PR c++/104291 | |
511 | * pt.cc (for_each_template_parm_r) <case CONSTRUCTOR>: Clear | |
512 | walk_subtrees if !include_nondeduced_p. Simplify given that | |
513 | cp_walk_subtrees already walks TYPE_PTRMEMFUNC_FN_TYPE_RAW. | |
514 | ||
f6f2d6cf GA |
515 | 2022-01-28 Patrick Palka <ppalka@redhat.com> |
516 | Jason Merrill <jason@redhat.com> | |
517 | ||
518 | PR c++/92752 | |
519 | * typeck.cc (build_ptrmemfunc): Cast a nullptr constant to the | |
520 | unqualified pointer type not the qualified one. | |
521 | ||
522 | 2022-01-28 Patrick Palka <ppalka@redhat.com> | |
523 | ||
524 | PR c++/103341 | |
525 | * decl.cc (cp_finish_decl): Pass the template arguments of a | |
526 | variable template specialization or a templated static data | |
527 | member to do_auto_deduction when the auto is constrained. | |
528 | ||
529 | 2022-01-28 Jason Merrill <jason@redhat.com> | |
530 | ||
531 | PR c++/100198 | |
532 | PR c++/100030 | |
533 | PR c++/100282 | |
534 | * parser.cc (cp_parser_enumerator_definition): Sorry on parameter | |
535 | pack in lambda. | |
536 | (cp_parser_class_head): And in class attributes. | |
537 | * pt.cc (check_for_bare_parameter_packs): Sorry instead of error | |
538 | in lambda. | |
539 | ||
99f17e99 GA |
540 | 2022-01-27 Jason Merrill <jason@redhat.com> |
541 | ||
542 | PR c++/104245 | |
543 | PR c++/51344 | |
544 | * decl2.cc (save_template_attributes): Take late attrs as parm. | |
545 | (cplus_decl_attributes): Call it after decl_attributes, | |
546 | splice_template_attributes before. | |
547 | ||
548 | 2022-01-27 Patrick Palka <ppalka@redhat.com> | |
549 | ||
550 | PR c++/99895 | |
551 | * call.cc (build_over_call): For a non-dependent member call, | |
552 | build up a CALL_EXPR using a COMPONENT_REF callee, as in | |
553 | build_new_method_call. | |
554 | * pt.cc (build_non_dependent_expr): Don't wrap PARM_DECL either. | |
555 | * tree.cc (build_min_non_dep_op_overload): Adjust accordingly | |
556 | after the build_over_call change. | |
557 | ||
558 | 2022-01-27 Patrick Palka <ppalka@redhat.com> | |
559 | ||
560 | PR c++/92944 | |
561 | PR c++/103678 | |
562 | * parser.cc (cp_parser_class_head): Update 'type' with the result | |
563 | of maybe_process_partial_specialization in the | |
564 | nested_name_specifier branch. Refactor nearby code to accomodate | |
565 | that maybe_process_partial_specialization returns a _TYPE, not a | |
566 | TYPE_DECL, and eliminate local variable 'class_type' in passing. | |
567 | ||
568 | 2022-01-27 Marek Polacek <polacek@redhat.com> | |
569 | ||
570 | PR c++/101988 | |
571 | * decl.cc (create_array_type_for_decl): Reject forming an array of | |
572 | placeholder for a deduced class type. | |
573 | ||
eaa59070 GA |
574 | 2022-01-26 Jason Merrill <jason@redhat.com> |
575 | ||
576 | PR c++/104206 | |
577 | PR c++/101072 | |
578 | * semantics.cc (finish_compound_literal): Restore VECTOR_TYPE check. | |
579 | ||
580 | 2022-01-26 Jakub Jelinek <jakub@redhat.com> | |
581 | ||
582 | PR c++/104226 | |
583 | * constexpr.cc (init_subob_ctx): For vector ctors containing | |
584 | vector elements, ensure appending to the same ctor instead of | |
585 | creating another one. | |
586 | ||
587 | 2022-01-26 Marek Polacek <polacek@redhat.com> | |
588 | ||
589 | PR target/104213 | |
590 | * decl.cc (finish_constructor_body): Suppress -Wuse-after-free. | |
591 | (finish_destructor_body): Likewise. | |
592 | * optimize.cc (build_delete_destructor_body): Likewise. | |
593 | ||
594 | 2022-01-26 Jason Merrill <jason@redhat.com> | |
595 | ||
596 | PR c++/104235 | |
597 | * parser.cc (cp_parser_template_name): Repeat lookup of USING_DECL. | |
598 | ||
599 | 2022-01-26 Jason Merrill <jason@redhat.com> | |
600 | ||
601 | PR c++/103057 | |
602 | * pt.cc (tsubst_aggr_type): Call tsubst for alias template | |
603 | specialization. | |
604 | ||
e0b8716f GA |
605 | 2022-01-25 Patrick Palka <ppalka@redhat.com> |
606 | ||
607 | PR c++/101532 | |
608 | PR c++/104225 | |
609 | * decl2.cc (mark_used): Don't consider maybe_instantiate_noexcept | |
610 | on a deleted function. | |
611 | ||
612 | 2022-01-25 Jason Merrill <jason@redhat.com> | |
613 | ||
614 | PR c++/59950 | |
615 | * call.cc (build_over_call): Use cp_build_indirect_ref. | |
616 | ||
bb99171b GA |
617 | 2022-01-24 Patrick Palka <ppalka@redhat.com> |
618 | ||
619 | PR c++/104197 | |
620 | * pt.cc (make_auto_1): Use -1 as a placeholder default argument | |
621 | for level. | |
622 | ||
623 | 2022-01-24 Patrick Palka <ppalka@redhat.com> | |
624 | ||
625 | PR c++/104173 | |
626 | * typeck.cc (build_class_member_access_expr): Extend | |
627 | unary_complex_lvalue result adjustment to preserve all | |
628 | rvalues, not just xvalues. | |
629 | ||
0c940703 GA |
630 | 2022-01-23 Will Wray <wjwray@gmail.com> |
631 | ||
632 | PR c++/55227 | |
633 | * decl.cc (reshape_init_r): Only call has_designator_check when | |
634 | first_initializer_p or for the inner constructor element. | |
635 | (cp_complete_array_type): Call reshape_init on braced-init-list. | |
636 | ||
637 | 2022-01-23 Jason Merrill <jason@redhat.com> | |
638 | ||
639 | PR c++/104182 | |
640 | * cp-gimplify.cc (cp_genericize_target_expr): Make sure nothing | |
641 | has set DECL_INITIAL on a TARGET_EXPR slot. | |
642 | * tree.cc (is_local_temp): Don't check DECL_CONTEXT. | |
643 | ||
644 | 2022-01-23 Jason Merrill <jason@redhat.com> | |
645 | ||
646 | PR c++/101072 | |
647 | * cp-tree.h (build_implicit_conv_flags): Declare. | |
648 | * call.cc (build_implicit_conv_flags): Split out from... | |
649 | (perform_implicit_conversion_flags): ...here. | |
650 | * decl.cc (check_initializer): Use it. | |
651 | * pt.cc (tsubst_copy_and_build): Remove TARGET_EXPR handling. | |
652 | * semantics.cc (finish_compound_literal): Don't treat | |
653 | scalar values like CONSTRUCTORs. | |
654 | ||
9dd44357 GA |
655 | 2022-01-21 Jason Merrill <jason@redhat.com> |
656 | ||
657 | * semantics.cc (find_failing_clause): Return expr if not | |
658 | decomposable. | |
659 | (finish_static_assert): Show constant values in failing | |
660 | comparison. | |
661 | ||
662 | 2022-01-21 Jason Merrill <jason@redhat.com> | |
663 | ||
664 | PR c++/104084 | |
665 | PR c++/20040 | |
666 | * init.cc (build_new_1): Only pull out TARGET_EXPR_INITIAL if | |
667 | alloc_expr is a TARGET_EXPR. | |
668 | ||
669 | 2022-01-21 Marek Polacek <polacek@redhat.com> | |
670 | ||
671 | PR c++/101715 | |
672 | * tree.cc (fixup_deferred_exception_variants): Remove duplicate | |
673 | variants after parsing the exception specifications. | |
674 | ||
675 | 2022-01-21 Jason Merrill <jason@redhat.com> | |
676 | ||
677 | PR c++/104139 | |
678 | PR c++/103681 | |
679 | * class.cc (end_of_class): Use base_binfo. | |
680 | ||
5fa55d55 GA |
681 | 2022-01-20 Jason Merrill <jason@redhat.com> |
682 | ||
683 | PR c++/101405 | |
684 | * decl.cc (reshape_init_class): Reject designator for a member of | |
685 | another class. | |
686 | ||
687 | 2022-01-20 Patrick Palka <ppalka@redhat.com> | |
688 | ||
689 | PR c++/91911 | |
690 | PR c++/103672 | |
691 | * pt.cc (keep_template_parm): Punt on a level 0 template parm. | |
692 | (tsubst_decl) <case VAR_DECL>: Remove !CHECKING_P safeguard. | |
693 | (tsubst) <case TEMPLATE_TYPE_PARM>: Handle CTAD placeholders | |
694 | specially. | |
695 | (make_auto_1): Add defaulted 'level' parameter. | |
696 | (make_template_placeholder): Pass 0 as 'level' to make_auto_1. | |
697 | ||
698 | 2022-01-20 Patrick Palka <ppalka@redhat.com> | |
699 | ||
700 | * decl.cc (grokdeclarator): Diagnose a CTAD placeholder as | |
701 | function return type even when !funcdecl_p. | |
702 | ||
703 | 2022-01-20 Martin Liska <mliska@suse.cz> | |
704 | ||
705 | PR c++/104134 | |
706 | * error.cc (dump_aggr_type): Partially disable the warning. | |
707 | ||
708 | 2022-01-20 Jason Merrill <jason@redhat.com> | |
709 | ||
710 | PR c++/102300 | |
711 | * parser.cc (cp_parser_template_name): Use dependent_scope_p. | |
712 | ||
fe1ad141 GA |
713 | 2022-01-19 David Malcolm <dmalcolm@redhat.com> |
714 | ||
715 | * cp-lang.cc (selftest::run_cp_tests): Update calls for .c to .cc | |
716 | renaming. | |
717 | * cp-tree.h (cp_pt_c_tests): Rename to... | |
718 | (cp_pt_cc_tests): ...this. | |
719 | (cp_tree_c_tests): Rename to... | |
720 | (cp_tree_cc_tests): ...this. | |
721 | * pt.cc (cp_pt_c_tests): Rename to... | |
722 | (cp_pt_cc_tests): ...this. | |
723 | * tree.cc (cp_tree_c_tests): Rename to... | |
724 | (cp_tree_cc_tests): ...this. | |
725 | ||
726 | 2022-01-19 Jason Merrill <jason@redhat.com> | |
727 | ||
728 | * parser.cc (saved_token_sentinel::rollback): Use | |
729 | cp_lexer_previous_token. | |
730 | ||
7a761ae6 GA |
731 | 2022-01-18 Jakub Jelinek <jakub@redhat.com> |
732 | ||
733 | PR c++/104055 | |
734 | * constexpr.cc (cxx_eval_outermost_constant_expr): If t is a | |
735 | TARGET_EXPR with TARGET_EXPR_CLEANUP, use get_target_expr rather | |
736 | than get_target_expr_sfinae with tf_no_cleanup, and don't set | |
737 | TREE_CONSTANT. | |
738 | ||
739 | 2022-01-18 Jason Merrill <jason@redhat.com> | |
740 | Jakub Jelinek <jakub@redhat.com> | |
741 | ||
742 | PR c++/104025 | |
743 | * parser.cc (saved_token_sentinel::rollback): Call | |
744 | cp_lexer_set_source_position. | |
745 | (~saved_token_sentinel): Call rollback. | |
746 | ||
747 | 2022-01-18 Patrick Palka <ppalka@redhat.com> | |
748 | ||
749 | PR c++/104074 | |
750 | * pt.cc (invalid_nontype_parm_type_p): Use WILDCARD_TYPE_P so | |
751 | that we return false for DEPENDENT_OPERATOR_TYPE too. | |
752 | ||
fc829782 GA |
753 | 2022-01-17 Martin Liska <mliska@suse.cz> |
754 | ||
755 | * Make-lang.in: Rename .c names to .cc. | |
756 | * config-lang.in: Likewise. | |
757 | * constexpr.cc (cxx_eval_constant_expression): Likewise. | |
758 | * coroutines.cc (morph_fn_to_coro): Likewise. | |
759 | * cp-gimplify.cc (cp_gimplify_expr): Likewise. | |
760 | * cp-lang.cc (struct lang_hooks): Likewise. | |
761 | (get_template_argument_pack_elems_folded): Likewise. | |
762 | * cp-objcp-common.cc (cp_tree_size): Likewise. | |
763 | (cp_unit_size_without_reusable_padding): Likewise. | |
764 | (pop_file_scope): Likewise. | |
765 | (cp_pushdecl): Likewise. | |
766 | * cp-objcp-common.h (GCC_CP_OBJCP_COMMON): Likewise. | |
767 | (cxx_simulate_record_decl): Likewise. | |
768 | * cp-tree.h (struct named_label_entry): Likewise. | |
769 | (current_function_return_value): Likewise. | |
770 | (more_aggr_init_expr_args_p): Likewise. | |
771 | (get_function_version_dispatcher): Likewise. | |
772 | (common_enclosing_class): Likewise. | |
773 | (strip_fnptr_conv): Likewise. | |
774 | (current_decl_namespace): Likewise. | |
775 | (do_aggregate_paren_init): Likewise. | |
776 | (cp_check_const_attributes): Likewise. | |
777 | (qualified_name_lookup_error): Likewise. | |
778 | (generic_targs_for): Likewise. | |
779 | (mark_exp_read): Likewise. | |
780 | (is_global_friend): Likewise. | |
781 | (maybe_reject_flexarray_init): Likewise. | |
782 | (module_token_lang): Likewise. | |
783 | (handle_module_option): Likewise. | |
784 | (literal_integer_zerop): Likewise. | |
785 | (build_extra_args): Likewise. | |
786 | (build_if_nonnull): Likewise. | |
787 | (maybe_check_overriding_exception_spec): Likewise. | |
788 | (finish_omp_target_clauses): Likewise. | |
789 | (maybe_warn_zero_as_null_pointer_constant): Likewise. | |
790 | (cxx_print_error_function): Likewise. | |
791 | (decl_in_std_namespace_p): Likewise. | |
792 | (merge_exception_specifiers): Likewise. | |
793 | (mangle_module_global_init): Likewise. | |
794 | (cxx_block_may_fallthru): Likewise. | |
795 | (fold_builtin_source_location): Likewise. | |
796 | (enum cp_oracle_request): Likewise. | |
797 | (subsumes): Likewise. | |
798 | (cp_finish_injected_record_type): Likewise. | |
799 | (vtv_build_vtable_verify_fndecl): Likewise. | |
800 | (cp_tree_c_finish_parsing): Likewise. | |
801 | * cvt.cc (diagnose_ref_binding): Likewise. | |
802 | (convert_to_void): Likewise. | |
803 | (convert_force): Likewise. | |
804 | (type_promotes_to): Likewise. | |
805 | * decl.cc (make_unbound_class_template_raw): Likewise. | |
806 | (cxx_init_decl_processing): Likewise. | |
807 | (check_class_member_definition_namespace): Likewise. | |
808 | (cxx_maybe_build_cleanup): Likewise. | |
809 | * decl2.cc (maybe_emit_vtables): Likewise. | |
810 | * error.cc (dump_function_name): Likewise. | |
811 | * init.cc (is_class_type): Likewise. | |
812 | (build_new_1): Likewise. | |
813 | * lang-specs.h: Likewise. | |
814 | * method.cc (make_alias_for_thunk): Likewise. | |
815 | * module.cc (specialization_add): Likewise. | |
816 | (module_state::read_cluster): Likewise. | |
817 | * name-lookup.cc (check_extern_c_conflict): Likewise. | |
818 | * name-lookup.h (struct cxx_binding): Likewise. | |
819 | * parser.cc (cp_parser_identifier): Likewise. | |
820 | * parser.h (struct cp_parser): Likewise. | |
821 | * pt.cc (has_value_dependent_address): Likewise. | |
822 | (push_tinst_level_loc): Likewise. | |
823 | * semantics.cc (finish_omp_clauses): Likewise. | |
824 | (finish_omp_atomic): Likewise. | |
825 | * tree.cc (cp_save_expr): Likewise. | |
826 | (cp_free_lang_data): Likewise. | |
827 | * typeck.cc (cp_common_type): Likewise. | |
828 | (strip_array_domain): Likewise. | |
829 | (rationalize_conditional_expr): Likewise. | |
830 | (check_return_expr): Likewise. | |
831 | * vtable-class-hierarchy.cc: Likewise. | |
832 | ||
833 | 2022-01-17 Martin Liska <mliska@suse.cz> | |
834 | ||
835 | * call.c: Moved to... | |
836 | * call.cc: ...here. | |
837 | * class.c: Moved to... | |
838 | * class.cc: ...here. | |
839 | * constexpr.c: Moved to... | |
840 | * constexpr.cc: ...here. | |
841 | * cp-gimplify.c: Moved to... | |
842 | * cp-gimplify.cc: ...here. | |
843 | * cp-lang.c: Moved to... | |
844 | * cp-lang.cc: ...here. | |
845 | * cp-objcp-common.c: Moved to... | |
846 | * cp-objcp-common.cc: ...here. | |
847 | * cp-ubsan.c: Moved to... | |
848 | * cp-ubsan.cc: ...here. | |
849 | * cvt.c: Moved to... | |
850 | * cvt.cc: ...here. | |
851 | * cxx-pretty-print.c: Moved to... | |
852 | * cxx-pretty-print.cc: ...here. | |
853 | * decl.c: Moved to... | |
854 | * decl.cc: ...here. | |
855 | * decl2.c: Moved to... | |
856 | * decl2.cc: ...here. | |
857 | * dump.c: Moved to... | |
858 | * dump.cc: ...here. | |
859 | * error.c: Moved to... | |
860 | * error.cc: ...here. | |
861 | * except.c: Moved to... | |
862 | * except.cc: ...here. | |
863 | * expr.c: Moved to... | |
864 | * expr.cc: ...here. | |
865 | * friend.c: Moved to... | |
866 | * friend.cc: ...here. | |
867 | * g++spec.c: Moved to... | |
868 | * g++spec.cc: ...here. | |
869 | * init.c: Moved to... | |
870 | * init.cc: ...here. | |
871 | * lambda.c: Moved to... | |
872 | * lambda.cc: ...here. | |
873 | * lex.c: Moved to... | |
874 | * lex.cc: ...here. | |
875 | * mangle.c: Moved to... | |
876 | * mangle.cc: ...here. | |
877 | * method.c: Moved to... | |
878 | * method.cc: ...here. | |
879 | * name-lookup.c: Moved to... | |
880 | * name-lookup.cc: ...here. | |
881 | * optimize.c: Moved to... | |
882 | * optimize.cc: ...here. | |
883 | * parser.c: Moved to... | |
884 | * parser.cc: ...here. | |
885 | * pt.c: Moved to... | |
886 | * pt.cc: ...here. | |
887 | * ptree.c: Moved to... | |
888 | * ptree.cc: ...here. | |
889 | * rtti.c: Moved to... | |
890 | * rtti.cc: ...here. | |
891 | * search.c: Moved to... | |
892 | * search.cc: ...here. | |
893 | * semantics.c: Moved to... | |
894 | * semantics.cc: ...here. | |
895 | * tree.c: Moved to... | |
896 | * tree.cc: ...here. | |
897 | * typeck.c: Moved to... | |
898 | * typeck.cc: ...here. | |
899 | * typeck2.c: Moved to... | |
900 | * typeck2.cc: ...here. | |
901 | * vtable-class-hierarchy.c: Moved to... | |
902 | * vtable-class-hierarchy.cc: ...here. | |
903 | ||
904 | 2022-01-17 Jakub Jelinek <jakub@redhat.com> | |
905 | ||
906 | PR c++/104031 | |
907 | * cp-gimplify.c (cp_genericize_target_expr): Set DECL_CONTEXT of | |
908 | TARGET_EXPR_SLOT to current_function_decl if it was NULL. | |
909 | ||
910 | 2022-01-17 Andrew Stubbs <ams@codesourcery.com> | |
911 | ||
912 | * parser.c (cp_parser_omp_requires): Don't "sorry" dynamic_allocators. | |
913 | ||
617db51d GA |
914 | 2022-01-14 Chung-Lin Tang <cltang@codesourcery.com> |
915 | ||
916 | PR c++/103705 | |
917 | * semantics.c (finish_omp_clauses): Also continue peeling off of | |
918 | outer node for ARRAY_REFs. | |
919 | ||
920 | 2022-01-14 Jakub Jelinek <jakub@redhat.com> | |
921 | ||
922 | PR c++/103991 | |
923 | * cp-objcp-common.c (cxx_block_may_fallthru) <case IF_STMT>: For | |
924 | IF_STMT_CONSTEXPR_P with constant false or true condition only | |
925 | check if the taken clause may fall through. | |
926 | * cp-gimplify.c (genericize_if_stmt): For consteval if, revert | |
927 | to r12-5638^ behavior if then_ block can't fall through. For | |
928 | constexpr if, revert to r12-5638^ behavior. | |
929 | ||
ad3f0d08 GA |
930 | 2022-01-13 Anthony Sharp <anthonysharp15@gmail.com> |
931 | Jason Merrill <jason@redhat.com> | |
932 | ||
933 | PR c++/70417 | |
934 | * parser.c (cp_parser_id_expression): Handle | |
935 | -Wmissing-template-keyword. | |
936 | (struct saved_token_sentinel): Add modes to control what happens | |
937 | on destruction. | |
938 | (cp_parser_statement): Adjust. | |
939 | (cp_parser_skip_entire_template_parameter_list): New function that | |
940 | skips an entire template parameter list. | |
941 | (cp_parser_require_end_of_template_parameter_list): Rename old | |
942 | cp_parser_skip_to_end_of_template_parameter_list. | |
943 | (cp_parser_skip_to_end_of_template_parameter_list): Refactor to be | |
944 | called from one of the above two functions. | |
945 | (cp_parser_lambda_declarator_opt) | |
946 | (cp_parser_explicit_template_declaration) | |
947 | (cp_parser_enclosed_template_argument_list): Adjust. | |
948 | ||
02a8a01b GA |
949 | 2022-01-12 Jakub Jelinek <jakub@redhat.com> |
950 | Jason Merrill <jason@redhat.com> | |
951 | ||
952 | PR c++/103480 | |
953 | * tree.c (move): If expr is xvalue_p, just return expr without | |
954 | build_static_cast. | |
955 | ||
01a254e3 GA |
956 | 2022-01-11 Jakub Jelinek <jakub@redhat.com> |
957 | ||
958 | PR c++/101597 | |
959 | * class.c (build_vfn_ref): Build OBJ_TYPE_REF with INTEGER_CST | |
960 | OBJ_TYPE_REF_TOKEN with type equal to OBJ_TYPE_REF_OBJECT type. | |
961 | * error.c (resolve_virtual_fun_from_obj_type_ref): Use type of | |
962 | OBJ_TYPE_REF_TOKEN rather than type of OBJ_TYPE_REF_OBJECT as | |
963 | obj_type. | |
964 | ||
965 | 2022-01-11 Patrick Palka <ppalka@redhat.com> | |
966 | ||
967 | PR c++/103831 | |
968 | * call.c (build_new_method_call): Consider dependent bases only | |
969 | if 'this' is available. | |
970 | ||
971 | 2022-01-11 Olivier Hainque <hainque@adacore.com> | |
972 | ||
973 | * decl.c (cxx_init_decl_processing): Move code possibly | |
974 | altering flag_weak before code testing it. | |
975 | ||
d9450aa0 GA |
976 | 2022-01-10 Patrick Palka <ppalka@redhat.com> |
977 | ||
978 | PR c++/103879 | |
979 | * constexpr.c (cxx_fold_indirect_ref): Split out object/offset | |
980 | canonicalization step into a local lambda. Strengthen it to | |
981 | absorb more components at position 0. Use it before both calls | |
982 | to cxx_fold_indirect_ref_1. | |
983 | ||
984 | 2022-01-10 Patrick Palka <ppalka@redhat.com> | |
985 | ||
986 | PR c++/103783 | |
987 | * call.c (cand_parms_match): Skip over 'this' when given one | |
988 | static and one non-static member function. | |
989 | ||
990 | 2022-01-10 Jakub Jelinek <jakub@redhat.com> | |
991 | ||
992 | PR c++/103912 | |
993 | * semantics.c (expand_or_defer_fn): For immediate functions, set | |
994 | node->body_removed to true and clear analyzed, definition and | |
995 | force_output. | |
996 | * decl2.c (c_parse_final_cleanups): Ignore immediate functions for | |
997 | expand_or_defer_fn. | |
998 | ||
2848ef14 GA |
999 | 2022-01-08 Jakub Jelinek <jakub@redhat.com> |
1000 | ||
1001 | PR c++/89074 | |
1002 | * constexpr.c (cxx_maybe_fold_addr_pointer_plus): New function. | |
1003 | (cxx_eval_binary_expression): Use it. | |
1004 | ||
1005 | 2022-01-08 Jason Merrill <jason@redhat.com> | |
1006 | ||
1007 | PR c++/103946 | |
1008 | * init.c (build_vec_init): Remove assert. | |
1009 | * tree.c (build_vec_init_expr): Likewise. | |
1010 | ||
1011 | 2022-01-08 Jason Merrill <jason@redhat.com> | |
1012 | ||
1013 | PR c++/100588 | |
1014 | * call.c (build_op_delete_call): Ignore destroying delete | |
1015 | if alloc_fn. | |
1016 | ||
55e96bf9 GA |
1017 | 2022-01-07 Jason Merrill <jason@redhat.com> |
1018 | ||
1019 | PR c++/20040 | |
1020 | * init.c (build_new_1): Also build pointer cleanup if | |
1021 | TYPE_GETS_DELETE. | |
1022 | * cp-tree.h (TYPE_GETS_VEC_DELETE): New. | |
1023 | ||
1024 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1025 | ||
1026 | PR c++/103936 | |
1027 | PR c++/65591 | |
1028 | * cp-gimplify.c (cp_gimplify_expr): Restore VEC_INIT_EXPR handling. | |
1029 | ||
1030 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1031 | ||
1032 | PR c++/103711 | |
1033 | * init.c (perform_target_ctor): Select destructor by in_chrg. | |
1034 | ||
1035 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1036 | ||
1037 | PR c++/61611 | |
1038 | * except.c (in_nested_catch): New. | |
1039 | (expand_end_catch_block): Check it. | |
1040 | ||
1041 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1042 | ||
1043 | PR c++/33799 | |
1044 | PR c++/102191 | |
1045 | * except.c (maybe_splice_retval_cleanup): Check | |
1046 | current_binding_level. | |
1047 | * semantics.c (do_poplevel): Call it here. | |
1048 | * parser.c (cp_parser_compound_statement): Not here. | |
1049 | ||
1050 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1051 | ||
1052 | PR c++/53868 | |
1053 | * decl.c (cp_finish_decl): Use wrap_temporary_cleanups for | |
1054 | cleanups from set_up_extended_ref_temp. | |
1055 | (wrap_temporary_cleanups): Ignore array cleanups. | |
1056 | (initialize_local_var): Don't check for array here. | |
1057 | * cp-tree.h (BIND_EXPR_VEC_DTOR): New. | |
1058 | * init.c (build_vec_delete_1): Set it. | |
1059 | ||
1060 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1061 | ||
1062 | PR c++/66451 | |
1063 | * init.c (build_vec_delete_1): Handle throwing dtor. | |
1064 | (build_vec_init): Tell it we're in a cleanup already. | |
1065 | ||
1066 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1067 | ||
1068 | * typeck2.c (split_nonconstant_init_1): Don't cleanup the last elt. | |
1069 | (split_nonconstant_init): Adjust. | |
1070 | ||
1071 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1072 | ||
1073 | PR c++/66139 | |
1074 | PR c++/52320 | |
1075 | * constexpr.c (replace_decl): Rename from replace_result_decl. | |
1076 | * cp-tree.h (replace_decl): Declare it. | |
1077 | * cp-gimplify.c (cp_gimplify_init_expr): Call it. | |
1078 | (cp_gimplify_expr): Don't handle VEC_INIT_EXPR. | |
1079 | (cp_genericize_init, cp_genericize_init_expr) | |
1080 | (cp_genericize_target_expr): New. | |
1081 | (cp_fold_r): Call them. | |
1082 | * tree.c (build_array_copy): Add a TARGET_EXPR. | |
1083 | * typeck2.c (digest_init_r): Look through a TARGET_EXPR. | |
1084 | ||
1085 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1086 | ||
1087 | PR c++/94041 | |
1088 | * decl.c (initialize_local_var): Fix comment. | |
1089 | * init.c (build_new_1): Do stabilize array init. | |
1090 | (build_vec_init): Use TARGET_EXPR for cleanup. Initialization | |
1091 | of an element from an explicit initializer is not a | |
1092 | full-expression. | |
1093 | * tree.c (expand_vec_init_expr): Pass flags through. | |
1094 | * typeck2.c (split_nonconstant_init_1): Handle VEC_INIT_EXPR. | |
1095 | (split_nonconstant_init): Handle array cleanups. | |
1096 | * cp-tree.h: Adjust. | |
1097 | ||
1098 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1099 | ||
1100 | PR c++/94041 | |
1101 | * decl.c (check_initializer): Remove obsolete comment. | |
1102 | (wrap_cleanups_r): Don't wrap CLEANUP_EH_ONLY. | |
1103 | (initialize_local_var): Change assert to test. | |
1104 | * typeck2.c (maybe_push_temp_cleanup): New. | |
1105 | (split_nonconstant_init_1): Use it. | |
1106 | (split_nonconstant_init): Clear cleanup flags. | |
1107 | ||
1108 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1109 | ||
1110 | PR c++/92385 | |
1111 | * typeck2.c (PICFLAG_VEC_INIT): New. | |
1112 | (process_init_constructor_array): Set it. | |
1113 | (process_init_constructor): Handle it. | |
1114 | (split_nonconstant_init_1): Handle VEC_INIT_EXPR. | |
1115 | * init.c (build_vec_init): Likewise. | |
1116 | * cp-gimplify.c (cp_gimplify_expr): Factor out... | |
1117 | * tree.c (expand_vec_init_expr): ...this function. | |
1118 | (build_vec_init_elt): Handle BRACE_ENCLOSED_INITIALIZER_P. | |
1119 | (build_vec_init_expr): Likewise. | |
1120 | * constexpr.c (cxx_eval_vec_init): Likewise. | |
1121 | (reduced_constant_expression_p): Check arrays before C++20. | |
1122 | * cp-tree.h (expand_vec_init_expr): Declare. | |
1123 | ||
1124 | 2022-01-07 Jason Merrill <jason@redhat.com> | |
1125 | ||
1126 | * init.c (build_new_1): Remove preevaluation code. | |
1127 | ||
0fbefa25 GA |
1128 | 2022-01-05 Nathan Sidwell <nathan@acm.org> |
1129 | ||
1130 | * pt.c (instantiate_class_template_1): Process attribute((used)) set | |
1131 | in class's context. | |
1132 | ||
1133 | 2022-01-05 Nathan Sidwell <nathan@acm.org> | |
1134 | ||
1135 | * init.c (build_new_1): Check complain before alignment warning. | |
1136 | ||
7d11b64b GA |
1137 | 2022-01-04 Jason Merrill <jason@redhat.com> |
1138 | ||
1139 | * cp-tree.h (class releasing_vec): Add begin/end fns. | |
1140 | ||
1141 | 2022-01-04 Jason Merrill <jason@redhat.com> | |
1142 | ||
1143 | * init.c: Include -*- C++ -*- on first line. | |
1144 | ||
a4ae8c37 GA |
1145 | 2022-01-03 Marek Polacek <polacek@redhat.com> |
1146 | ||
1147 | PR c++/103758 | |
1148 | * parser.c (cp_parser_decl_specifier_seq): Replace %<decl-specifier%> | |
1149 | with %qD. | |
1150 | ||
1151 | 2022-01-03 Marek Polacek <polacek@redhat.com> | |
1152 | ||
1153 | * parser.c (make_char_string_pack): Add a cast to const unsigned | |
1154 | char *. | |
1155 | ||
1156 | 2022-01-03 Jakub Jelinek <jakub@redhat.com> | |
1157 | ||
1158 | PR c++/103600 | |
1159 | * rtti.c (get_tinfo_decl_direct): Add "non overlapping" attribute | |
1160 | to DECL_TINFO_P VAR_DECLs. | |
1161 | ||
5da23a13 GA |
1162 | 2022-01-02 Jason Merrill <jason@redhat.com> |
1163 | ||
1164 | * init.c (build_vec_init): Append the decrement to elt_init. | |
1165 | ||
1166 | 2022-01-02 Jason Merrill <jason@redhat.com> | |
1167 | ||
1168 | * decl.c (wrap_cleanups_r): Don't wrap if noexcept. | |
1169 | ||
ad41bd84 | 1170 | \f |
6123f29a | 1171 | Copyright (C) 2022 Free Software Foundation, Inc. |
ad41bd84 JM |
1172 | |
1173 | Copying and distribution of this file, with or without modification, | |
1174 | are permitted in any medium without royalty provided the copyright | |
1175 | notice and this notice are preserved. |