9b071ebef9e8c6d52be63fc37b64c8132f0ac730
[gcc.git] / gcc / cp / ChangeLog
1 2017-02-19 Jason Merrill <jason@redhat.com>
2
3 PR c++/79503 - inherited ctor taking base class
4 * call.c (add_function_candidate): Also check that
5 DECL_INHERITED_CTOR_BASE is reference-related to the parameter type.
6
7 2017-02-19 Paolo Carlini <paolo.carlini@oracle.com>
8
9 PR c++/79380
10 * typeck.c (cxx_alignas_expr): Reject a non-integral alignas
11 argument.
12
13 2017-02-19 Eric Fiselier <eric@efcs.ca>
14 Jonathan Wakely <jwakely@redhat.com>
15
16 PR c++/69523
17 * parser.c (cp_parser_unqualified_id): Use OPT_Wliteral_suffix to
18 control warning about literal suffix identifiers without a leading
19 underscore.
20
21 2017-02-17 Jason Merrill <jason@redhat.com>
22
23 PR c++/79508 - lookup error with member template
24 * parser.c (cp_parser_template_name): Clear
25 parser->context->object_type if we aren't doing lookup.
26
27 PR c++/78690 - ICE with using and global type with same name
28 * pt.c (type_dependent_object_expression_p): True for
29 IDENTIFIER_NODE.
30
31 PR c++/79549 - C++17 ICE with non-type auto template parameter pack
32 * pt.c (convert_template_argument): Just return an auto arg pack.
33 (tsubst_template_args): Don't tsubst an auto pack type.
34
35 PR c++/79556 - C++17 ICE with non-type auto
36 * pt.c (do_auto_deduction): Don't try to deduce from null type.
37
38 PR c++/79533 - C++17 ICE with temporary cast to reference
39 * call.c (build_over_call): Conversion to a reference prevents copy
40 elision.
41
42 2017-02-16 Jakub Jelinek <jakub@redhat.com>
43 Jason Merrill <jason@redhat.com>
44
45 PR c++/79502 - lost nodiscard attribute
46 * pt.c (apply_late_template_attributes): Do apply non-dependent
47 attributes to types.
48
49 2017-02-16 Jason Merrill <jason@redhat.com>
50
51 PR c++/78572 - ICE with self-modifying array initializer
52 * constexpr.c (cxx_eval_store_expression): The object we're
53 initializing is outside the constant-expression.
54 (cxx_eval_call_expression): Set ctx->call.
55
56 PR c++/79050 - ICE with undeduced auto and LTO
57 * decl.c (poplevel): Remove undeduced auto decls.
58
59 2017-02-16 Jakub Jelinek <jakub@redhat.com>
60
61 PR c++/79512
62 * parser.c (cp_parser_omp_target): For -fopenmp-simd
63 ignore #pragma omp target even when not followed by identifier.
64
65 2017-02-15 Jason Merrill <jason@redhat.com>
66 Jakub Jelinek <jakub@redhat.com>
67
68 PR c++/79464 - ICE in IPA with omitted constructor parms
69 * class.c (build_clone): Also omit parms from TYPE_ARG_TYPES.
70 (adjust_clone_args): Adjust.
71 (add_method): Remember omitted parms.
72 * call.c (add_function_candidate): Likewise.
73 * mangle.c (write_method_parms): Likewise.
74 * method.c (ctor_omit_inherited_parms): Return false if there are no
75 parms to omit.
76
77 2017-02-15 Martin Sebor <msebor@redhat.com>
78
79 PR c++/79363
80 * init.c (maybe_reject_flexarray_init): New function.
81 (perform_member_init): Call it.
82
83 2017-02-15 Jakub Jelinek <jakub@redhat.com>
84
85 PR c++/79301
86 * parser.c (cp_parser_std_attribute): Don't pedwarn about
87 [[deprecated]] with -std=c++11 and [[fallthrough]] with
88 -std=c++11 and -std=c++14.
89
90 PR c++/79288
91 * decl.c (grokdeclarator): For static data members, handle thread_p
92 only after handling inline.
93
94 2017-02-14 Marek Polacek <polacek@redhat.com>
95
96 PR c++/79420
97 PR c++/79463
98 * parser.c (cp_parser_postfix_dot_deref_expression): Avoid
99 clobbering if the postfix expression isn't an EXPR_P.
100
101 2017-02-13 Jason Merrill <jason@redhat.com>
102
103 PR c++/79461 - ICE with lambda in constexpr constructor
104 * constexpr.c (build_data_member_initialization): Ignore
105 initialization of a local variable.
106
107 2017-02-13 Jakub Jelinek <jakub@redhat.com>
108
109 * init.c (warn_placement_new_too_small): Add missing space in
110 diagnostics.
111 * parser.c (cp_parser_oacc_declare): Likewise.
112 * mangle.c (maybe_check_abi_tags): Likewise.
113
114 PR c++/79232
115 * typeck.c (cp_build_modify_expr): Handle properly COMPOUND_EXPRs
116 on lhs that have {PRE{DEC,INC}REMENT,MODIFY,MIN,MAX,COND}_EXPR
117 in the rightmost operand.
118
119 2017-02-13 Nathan Sidwell <nathan@acm.org>
120
121 PR c++/79296 - ICE mangling localized template instantiation
122 * decl2.c (determine_visibility): Use template fn context for
123 local class instantiations.
124
125 2017-02-11 Jason Merrill <jason@redhat.com>
126
127 PR c++/77659 - ICE with new and C++14 aggregate NSDMI
128 * init.c (build_new): Make backups of any CONSTRUCTORs in init.
129 (build_new_1): Use replace_placeholders.
130 * tree.c (replace_placeholders_t): Also track whether we've seen a
131 placeholder.
132 (replace_placeholders, replace_placeholders_r): Adjust.
133 * cp-tree.h: Adjust.
134
135 PR c++/77790 - ICE with auto function in C++11 mode
136 * decl.c (undeduced_auto_decl): Remove C++14 limitation.
137 (require_deduced_type): Add complain parm, return bool.
138 * cp-tree.h: Adjust.
139 * decl2.c (mark_used): Use require_deduced_type.
140
141 2017-02-10 Jason Merrill <jason@redhat.com>
142
143 PR c++/78908 - template ops and bitfields
144 * tree.c (build_min_non_dep): Use unlowered_expr_type.
145
146 PR c++/78897 - constexpr union
147 * constexpr.c (cxx_eval_store_expression): A store to a union member
148 erases a previous store to another member.
149
150 PR c++/71285 - member of fold-expression
151 * semantics.c (finish_unary_fold_expr)
152 (finish_binary_fold_expr): Use null type for fold-expressions.
153
154 PR c++/79401 - protected inherited constructor
155 * call.c (enforce_access): For inheriting constructor, find a base
156 binfo in the path we already have.
157
158 2017-02-10 Marek Polacek <polacek@redhat.com>
159
160 PR c++/79435
161 * pt.c (type_dependent_expression_p): Check if the expression type
162 is null.
163
164 PR c++/79184
165 * cvt.c (ocp_convert): Add a sentinel against -Wint-in-bool-context
166 if warnings shouldn't be given.
167
168 2017-02-10 Paolo Carlini <paolo.carlini@oracle.com>
169
170 PR c++/71737
171 * pt.c (tsubst_decl): Don't try to preserve a typedef that names
172 an error_mark_node as type.
173
174 2017-02-09 Jakub Jelinek <jakub@redhat.com>
175 Jason Merrill <jason@redhat.com>
176
177 PR c++/79143
178 * pt.c (instantiate_class_template_1): Copy CLASSTYPE_NON_AGGREGATE
179 from pattern to type.
180
181 2017-02-09 Jason Merrill <jason@redhat.com>
182
183 PR c++/79316 - default argument in deduction guide
184 PR c++/79350 - explicit deduction guide
185 * parser.c (cp_parser_constructor_declarator_p)
186 (cp_parser_direct_declarator): Parse deduction guides more like
187 constructors.
188 * cp-tree.h (enum special_function_kind): Add sfk_deduction_guide.
189 * tree.c (special_function_p): Return it.
190 * decl.c (check_special_function_return_type): Handle it.
191 (grokdeclarator, grokfndecl): Adjust.
192 (cp_finish_decl): Pass flags to do_auto_deduction.
193 * error.c (dump_decl_name): Use TFF_UNQUALIFIED_NAME.
194 * pt.c (dguide_name_p): Take a const_tree.
195 (do_class_deduction): Handle explicit.
196 (do_auto_deduction): Pass flags through.
197 (build_deduction_guide): Copy explicit flag.
198
199 2017-02-09 Jakub Jelinek <jakub@redhat.com>
200
201 PR c++/79429
202 * parser.c (cp_parser_omp_ordered): Don't check for non-pragma_stmt
203 non-pragma_compound context here.
204 (cp_parser_omp_target): Likewise.
205 (cp_parser_pragma): Don't call push_omp_privatization_clauses and
206 parsing for ordered and target omp pragmas in non-pragma_stmt
207 non-pragma_compound contexts.
208
209 PR c/79431
210 * parser.c (cp_parser_oacc_declare): Formatting fix.
211 (cp_parser_omp_declare_target): Don't invoke symtab_node::get on
212 automatic variables.
213
214 2016-02-09 Nathan Sidwell <nathan@codesourcery.com>
215 Chung-Lin Tang <cltang@codesourcery.com>
216
217 * parser.c (cp_parser_oacc_clause_tile): Disallow collapse. Fix
218 parsing. Parse constant expression. Remove semantic checking.
219 (cp_parser_omp_clause_collapse): Disallow tile.
220 (cp_parser_omp_for_loop): Deal with tile clause. Don't emit a parse
221 error about missing for after already emitting one. Use more
222 conventional for idiom for unbounded loop.
223 * pt.c (tsubst_omp_clauses): Handle OMP_CLAUSE_TILE.
224 * semantics.c (finish_omp_clauses): Correct TILE semantic check.
225 (finish_omp_for): Deal with tile clause.
226
227 2017-02-07 Nathan Sidwell <nathan@acm.org>
228
229 * method.c (synthesized_method_base_walk): New. Broken out of ...
230 (synthesized_method_walk): ... here. Call it. Cleanup
231 initializations.
232
233 2017-02-07 Patrick Palka <ppalka@gcc.gnu.org>
234
235 PR c++/79360
236 * typeck2.c (process_init_constructor_union): Consider only
237 FIELD_DECLs when looking for an NSDMI.
238
239 2017-02-06 Jason Merrill <jason@redhat.com>
240
241 PR c++/71193 - incomplete types in templates
242 * parser.c (cp_parser_postfix_dot_deref_expression): In a template
243 handle incomplete type by pedwarning and then treating as dependent.
244
245 2017-02-06 Jakub Jelinek <jakub@redhat.com>
246
247 PR c++/79379
248 * constexpr.c (cxx_eval_constant_expression): Handle ANNOTATE_EXPR.
249 (potential_constant_expression_1): Likewise.
250
251 PR c++/79377
252 * tree.c (build_min_non_dep_op_overload): For POST{INC,DEC}REMENT_EXPR
253 allow one fewer than expected arguments if flag_permissive.
254
255 PR c++/79372
256 * decl.c (cp_finish_decomp): On error set decl type to error_mark_node.
257 * pt.c (tsubst_expr): Don't call tsubst_decomp_names on decompositions
258 with error_mark_node type.
259
260 2017-02-03 Jason Merrill <jason@redhat.com>
261
262 PR c++/78689 - ICE on constructor with label
263 * optimize.c (maybe_clone_body): Replace omitted parameters with
264 null lvalues.
265 * class.c (build_clone): Fix logic for omitting inherited parms.
266
267 PR c++/12245 - excessive memory use
268 * constexpr.c (maybe_constant_value): Fold maybe_constant_value_1
269 back in. Don't cache constants.
270 (maybe_constant_init): Don't cache constants.
271
272 PR c++/79294 - ICE with invalid template argument
273 * pt.c (convert_nontype_argument_function): Check value-dependence.
274 (convert_nontype_argument): Don't check it here for function ptrs.
275
276 2017-02-02 Richard Biener <rguenther@suse.de>
277
278 PR cp/14179
279 * cp-gimplify.c (cp_fold): When folding a CONSTRUCTOR copy
280 it lazily on the first changed element only and copy it
281 fully upfront, only storing changed elements.
282
283 2017-02-02 Paolo Carlini <paolo.carlini@oracle.com>
284
285 PR c++/69637
286 * decl2.c (grokbitfield): In case of error don't set-up DECL_INITIAL
287 to the width.
288
289 2017-01-31 Jakub Jelinek <jakub@redhat.com>
290
291 PR c++/79304
292 * error.c (dump_expr) <case COMPONENT_REF>: Don't print .
293 after ARROW_EXPR.
294
295 2017-01-31 David Malcolm <dmalcolm@redhat.com>
296
297 PR c++/79298
298 * name-lookup.c (suggest_alternative_in_explicit_scope): Resolve
299 any namespace aliases.
300
301 2017-01-31 Nathan Sidwell <nathan@acm.org>
302
303 PR c++/79290
304 * typeck.c (build_ptrmemfunc_access_expr): Set TREE_NO_WARNING.
305
306 PR c++/67273
307 PR c++/79253
308 * pt.c: (instantiate_decl): Push to top level when current
309 function scope doesn't match. Only push lmabda scope stack when
310 pushing to top.
311
312 * cp-tree.h (instantiate_decl): Make defer_ok bool.
313 * pt.c: Fix instantiate_decl calls to pass true/false not 0/1
314 (instantiate_decl): Simplify and reorder state saving and restoration.
315
316 PR c++/79264
317 * lambda.c (maybe_generic_this_capture): Deal with template-id-exprs.
318 * semantics.c (finish_member_declaration): Assert class is being
319 defined.
320
321 2017-01-30 Alexandre Oliva <aoliva@redhat.com>
322
323 Introduce C++ support in libcc1.
324 * cp-tree.h (struct lang_identifier): Add oracle_looked_up.
325 (ansi_opname): Rename to...
326 (cp_operator_id): ... this. Adjust all callers.
327 (ansi_assopname): Rename to...
328 (cp_assignment_operator_id): ... this. Adjust all callers.
329 (cp_literal_operator_id): Declare.
330 (set_global_friend): Declare.
331 (is_global_friend): Declare.
332 (enum cp_oracle_request): New type.
333 (cp_binding_oracle_function): New type.
334 (cp_binding_oracle): Declare.
335 (cp_finish_injected_record_type): Declare.
336 * friend.c (global_friend): New var.
337 (set_global_friend): New fn.
338 (is_global_friend): New fn.
339 (is_friend): Call is_global_friend.
340 * name-lookup.c (cp_binding_oracle): New var.
341 (query_oracle): New fn.
342 (qualified_lookup_using_namespace): Call query_oracle.
343 (lookup_name_real_1): Likewise.
344 * parser.c (cp_literal_operator_id): Drop static.
345 * search.c (friend_accessible_p): Call is_global_friend.
346 * semantics.c (is_this_parameter): Accept a variable if the
347 binding oracle is enabled.
348
349 2017-01-27 Jason Merrill <jason@redhat.com>
350
351 PR c++/78771 - ICE with inherited constructor.
352 * call.c (build_over_call): Call deduce_inheriting_ctor here.
353 * pt.c (tsubst_decl): Not here.
354 * class.c (add_method): Or here.
355 * method.c (deduce_inheriting_ctor): Handle clones.
356 (implicitly_declare_fn): Don't deduce inheriting ctors yet.
357
358 2017-01-27 Adam Butcher <adam@jessamine.co.uk>
359
360 PR c++/64382
361 * cp/parser.c (parsing_default_capturing_generic_lambda_in_template):
362 New function.
363 * cp/cp-tree.h: Declare it.
364 * cp/semantics.c (finish_id_expression): Resolve names within a default
365 capturing generic lambda defined within a template prior to
366 instantiation to allow for captures to be added to the closure type.
367
368 2017-01-26 Jakub Jelinek <jakub@redhat.com>
369
370 PR c++/68727
371 * cp-tree.def (OFFSETOF_EXPR): Bump number of operands to 2.
372 * cp-tree.h (finish_offsetof): Add OBJECT_PTR argument.
373 * parser.c (cp_parser_builtin_offsetof): Pass result of
374 build_static_cast of null_pointer_node to finish_offsetof.
375 * semantics.c (finish_offsetof): Add OBJECT_PTR argument, use
376 it for -Winvalid-offsetof pedwarn instead of trying to guess
377 original offsetof type from EXPR. Save OBJECT_PTR as a new
378 second operand to OFFSETOF_EXPR.
379 * pt.c (tsubst_copy_and_build) <case OFFSETOF_EXPR>: Adjust
380 finish_offsetof caller, pass the second operand of OFFSETOF_EXPR
381 as OBJECT_PTR.
382
383 2017-01-26 Jason Merrill <jason@redhat.com>
384
385 * name-lookup.c (parse_using_directive): Deprecate strong using.
386
387 PR c++/79176 - lambda ICE with -flto -Os
388 * decl2.c (vague_linkage_p): Handle decloned 'tors.
389 * tree.c (decl_linkage): Likewise.
390
391 2017-01-25 Martin Sebor <msebor@redhat.com>
392
393 * decl.c (grokdeclarator): Fix a typo in a comment.
394
395 2017-01-25 Jakub Jelinek <jakub@redhat.com>
396
397 PR c++/78896
398 * decl.c (cp_finish_decomp): Disallow memberwise decomposition of
399 lambda expressions.
400
401 PR c++/77914
402 * parser.c (cp_parser_lambda_declarator_opt): Pedwarn with
403 OPT_Wpedantic on lambda templates for -std=c++14 and higher.
404
405 2017-01-25 Maxim Ostapenko <m.ostapenko@samsung.com>
406
407 PR lto/79061
408 * decl.c (cxx_init_decl_processing): Pass main_input_filename
409 to build_translation_unit_decl.
410
411 2017-01-24 Jakub Jelinek <jakub@redhat.com>
412
413 PR c++/79205
414 * cp-gimplify.c (cp_genericize_r): Add result of
415 convert_from_reference on invisiref parm to p_set.
416
417 2017-01-24 Nathan Sidwell <nathan@acm.org>
418
419 PR c++/78469 - defaulted ctor and inaccessible dtor
420 * cp-tree.h (tsubst_flags): Add tf_no_cleanup.
421 * init.c (build_new_1): Pass tf_no_cleanup to build_value_init.
422 * tree.c (build_target_expr): Check tf_no_cleanup.
423
424 PR c++/79118 - anon-members and constexpr
425 * constexpr.c (cx_check_missing_mem_inits): Caller passes type not
426 ctor decl. Recursively check anonymous members.
427 (register_constexpr_fundef): Adjust cx_check_missing_mem_inits
428 call.
429 (explain_invalid_constexpr_fn): Likewise.
430
431 2017-01-23 Nathan Sidwell <nathan@acm.org>
432
433 PR c++/71710 - template using directive of field
434 * pt.c (tsubst_copy_and_build [COMPONENT_REF]): Move FIELD_DECL
435 check earlier.
436
437 PR c++/71406 - ICE with scope-ref'd template id exprs
438 PR c++/77508
439 * typeck.c (finish_class_member_access_expr): Break up SCOPE_REF
440 before breaking up TEMPLATE_ID_EXPR.
441
442 2017-01-20 Nathan Sidwell <nathan@acm.org>
443
444 PR c++/78495 - wrong code inherited ctor and invisi-ref parm
445 * cp-gimplify.c (cp_generize_r): Don't skip thunks.
446
447 2017-01-20 David Malcolm <dmalcolm@redhat.com>
448
449 PR c++/77829
450 PR c++/78656
451 * cp-tree.h (suggest_alternatives_for): Add bool param.
452 (suggest_alternative_in_explicit_scope): New decl.
453 * error.c (qualified_name_lookup_error): When SCOPE is a namespace
454 that isn't the global one, call new function
455 suggest_alternative_in_explicit_scope, only calling
456 suggest_alternatives_for if it fails, and disabling near match
457 searches fort that case. When SCOPE is the global namespace,
458 pass true for new param to suggest_alternatives_for to allow for
459 fuzzy name lookups.
460 * lex.c (unqualified_name_lookup_error): Pass true for new param
461 to suggest_alternatives_for.
462 * name-lookup.c (consider_binding_level): Add forward decl.
463 (suggest_alternatives_for): Add "suggest_misspellings" param,
464 using it to conditionalize the fuzzy name-lookup code.
465 (suggest_alternative_in_explicit_scope): New function.
466 * parser.c (cp_parser_primary_expression): When calling
467 finish_id_expression, pass location of id_expression rather
468 than that of id_expr_token.
469 (cp_parser_id_expression): Convert local "unqualified_id" from
470 tree to cp_expr to avoid implicitly dropping location information.
471
472 2017-01-20 Marek Polacek <polacek@redhat.com>
473
474 PR c/64279
475 * call.c (build_conditional_expr_1): Warn about duplicated branches.
476 * semantics.c (finish_expr_stmt): Build statement using the proper
477 location.
478
479 2017-01-19 Jason Merrill <jason@redhat.com>
480
481 US 20 - forwarding references and class template argument deduction
482 * cp-tree.h (TEMPLATE_TYPE_PARM_FOR_CLASS): New.
483 * pt.c (push_template_decl_real): Set it.
484 (maybe_adjust_types_for_deduction): Check it.
485 (rewrite_template_parm): Copy it.
486
487 US 19 - deduction guides and constructors
488 * call.c (joust): Prefer deduction guides to constructors.
489 * pt.c (build_deduction_guide): Set DECL_ARTIFICIAL.
490 (deduction_guide_p): Check DECL_P.
491
492 * decl.c (check_initializer): Always use build_aggr_init for array
493 decomposition.
494
495 PR c++/79130 - decomposition and direct-initialization
496 * init.c (build_aggr_init): Communicate direct-initialization to
497 build_vec_init.
498 (build_vec_init): Check for array copy sooner.
499 * parser.c (cp_parser_decomposition_declaration): Remove call to
500 build_x_compound_expr_from_list.
501
502 2017-01-18 Jason Merrill <jason@redhat.com>
503
504 PR c++/68666 - member variable template-id
505 * typeck.c (finish_class_member_access_expr): Handle variable
506 template-id.
507 * pt.c (lookup_and_finish_template_variable): No longer static.
508 * cp-tree.h: Declare it.
509
510 2017-01-18 Nathan Sidwell <nathan@acm.org>
511
512 PR c++/78488
513 * call.c (build_over_call): When checking ellipsis conversions for
514 an inherited ctor, make sure there is at least one conversion.
515
516 2017-01-18 Jason Merrill <jason@redhat.com>
517
518 PR c++/78894 - ICE with class deduction and default arg
519 * pt.c (build_deduction_guide): Set DECL_PRIMARY_TEMPLATE.
520
521 2017-01-18 Markus Trippelsdorf <markus@trippelsdorf.de>
522
523 PR c++/77489
524 * mangle.c (write_discriminator): Reorganize abi warning check.
525
526 2017-01-18 Nathan Sidwell <nathan@acm.org>
527
528 * cp-tree.h: Clarify exception spec node comment.
529 * except.c (nothrow_spec_p): Simplify by checking node-equality.
530
531 PR c++/79091
532 * mangle.c (write_exception_spec): Check nothrow explicitly.
533 (write_encoding): Don't increment processing_template_decl around
534 encoding.
535
536 2017-01-18 Markus Trippelsdorf <markus@trippelsdorf.de>
537
538 PR c++/70182
539 * mangle.c (write_template_args): Add "on" for operator names.
540
541 2017-01-18 Markus Trippelsdorf <markus@trippelsdorf.de>
542
543 PR c++/77489
544 * mangle.c (write_discriminator): Handle discriminator >= 10.
545
546 2017-01-17 Nathan Sidwell <nathan@acm.org>
547
548 PR c++/61636
549 * cp-tree.h (maybe_generic_this_capture): Declare.
550 * lambda.c (resolvable_dummy_lambda): New, broken out of ...
551 (maybe_resolve_dummy): ... here. Call it.
552 (maybe_generic_this_capture): New.
553 * parser.c (cp_parser_postfix_expression): Speculatively capture
554 this in generic lambda in unresolved member function call.
555 * pt.c (tsubst_copy_and_build): Force hard error from failed
556 member function lookup in generic lambda.
557
558 2017-01-17 Aldy Hernandez <aldyh@redhat.com>
559
560 PR c++/70565
561 * cp-array-notation.c (expand_array_notation_exprs): Handle
562 OMP_PARALLEL.
563
564 2017-01-11 Jason Merrill <jason@redhat.com>
565
566 PR c++/78337 - ICE on invalid with generic lambda
567 * semantics.c (process_outer_var_ref): Check if containing_function
568 is null. Move inform call under complain test.
569
570 2017-01-11 Nathan Sidwell <nathan@acm.org>
571
572 PR c++/77812
573 * name-lookup.c (set_namespace_binding_1): An overload of 1 decl
574 is a new overload.
575
576 2017-01-11 Nathan Sidwell <nathan@acm.org>
577
578 * name-lookup.c (push_overloaded_decl_1): Refactor OVERLOAD creation.
579
580 2017-01-11 Jakub Jelinek <jakub@redhat.com>
581
582 PR c++/78341
583 * parser.c (cp_parser_std_attribute_spec): Remove over-eager
584 assertion. Formatting fix.
585
586 PR c++/72813
587 * decl2.c (c_parse_final_cleanups): Set flag_syntax_only to 1 after
588 writing PCH file.
589
590 2017-01-10 David Malcolm <dmalcolm@redhat.com>
591
592 PR c++/77949
593 * parser.c (cp_parser_class_specifier_1): Only suggest inserting
594 a missing semicolon if we have a valid insertion location for
595 the fix-it hint.
596
597 2017-01-10 Jason Merrill <jason@redhat.com>
598
599 FI 20, decomposition declaration with parenthesized initializer.
600 * parser.c (cp_parser_decomposition_declaration): Use
601 cp_parser_initializer.
602
603 2017-01-09 Jason Merrill <jason@redhat.com>
604
605 Implement P0195R2, C++17 variadic using.
606 * parser.c (cp_parser_using_declaration): Handle ellipsis and comma.
607 * pt.c (tsubst_decl): Handle pack expansion in USING_DECL_SCOPE.
608 * error.c (dump_decl): Likewise.
609
610 2017-01-09 Jakub Jelinek <jakub@redhat.com>
611
612 PR translation/79019
613 PR translation/79020
614 * semantics.c (finish_omp_clauses): Add missing whitespace to
615 translatable strings.
616 * cp-cilkplus.c (cpp_validate_cilk_plus_loop_aux): Fix comment typo.
617
618 2017-01-07 Jason Merrill <jason@redhat.com>
619
620 PR c++/78948 - instantiation from discarded statement
621 * parser.h (struct cp_parser): Remove in_discarded_stmt field.
622 * cp-tree.h (in_discarded_stmt): Declare it.
623 (struct saved_scope): Add discarded_stmt bitfield.
624 (in_discarded_stmt): New macro.
625 * decl2.c (mark_used): Check it.
626 * parser.c (cp_parser_selection_statement): Adjust.
627 (cp_parser_jump_statement): Adjust.
628
629 2017-01-05 Jakub Jelinek <jakub@redhat.com>
630
631 PR c++/78931
632 * decl.c (cp_finish_decomp): Remove probe variable, if tt is
633 REFERENCE_REF_P, set tt to its operand.
634
635 PR c++/78890
636 * class.c (check_field_decls): Diagnose REFERENCE_TYPE fields in
637 unions even for C++11 and later.
638
639 2017-01-05 Nathan Sidwell <nathan@acm.org>
640
641 PR c++/78765
642 * pt.c (convert_nontype_argument): Don't try and see if integral
643 or enum expressions are constants prematurely.
644
645 2017-01-04 Marek Polacek <polacek@redhat.com>
646
647 PR c++/64767
648 * typeck.c (cp_build_binary_op): Warn when a pointer is compared with
649 a zero character literal.
650
651 2017-01-04 Jakub Jelinek <jakub@redhat.com>
652
653 PR c++/78949
654 * typeck.c (cp_build_unary_op): Call mark_rvalue_use on arg if it has
655 vector type.
656
657 PR c++/78693
658 * parser.c (cp_parser_simple_declaration): Only complain about
659 inconsistent auto deduction if auto_result doesn't use auto.
660
661 * parser.c (cp_parser_simple_declaration): Diagnose function
662 declaration among more than one init-declarators with auto
663 specifier.
664
665 PR c++/71182
666 * parser.c (cp_lexer_previous_token): Use vec_safe_address in the
667 assertion, as lexer->buffer may be NULL.
668
669 2017-01-04 Marek Polacek <polacek@redhat.com>
670
671 PR c++/77545
672 PR c++/77284
673 * constexpr.c (potential_constant_expression_1): Handle CLEANUP_STMT.
674
675 2017-01-04 Nathan Sidwell <nathan@acm.org>
676
677 PR c++/66735
678 * cp-tree.h (DECLTYPE_FOR_REF_CAPTURE): New.
679 (lambda_capture_field_type): Update prototype.
680 * lambda.c (lambda_capture_field_type): Add is_reference parm.
681 Add referenceness here.
682 (add_capture): Adjust lambda_capture_field_type call, refactor
683 error checking.
684 * pt.c (tsubst): Adjust lambda_capture_field_type call.
685
686 2017-01-01 Jakub Jelinek <jakub@redhat.com>
687
688 Update copyright years.
689 \f
690 Copyright (C) 2017 Free Software Foundation, Inc.
691
692 Copying and distribution of this file, with or without modification,
693 are permitted in any medium without royalty provided the copyright
694 notice and this notice are preserved.