re PR c++/50800 (Internal compiler error in finish_member_declarations, possibly...
[official-gcc.git] / gcc / cp / ChangeLog
blob717aaa681782b6de28dbf18cf5bdb775f058a9c2
1 2015-04-23  Jason Merrill  <jason@redhat.com>
3         PR c++/50800
4         * tree.c (strip_typedefs): Add remove_attributes parm.
5         (strip_typedefs_expr): Likewise.
6         (apply_identity_attributes): New subroutine of strip_typedefs.
7         * pt.c (canonicalize_type_argument): Let strip_typedefs handle attrs.
8         (convert_nontype_argument, unify): Likewise.
9         * cp-tree.h: Adjust.
11         PR c++/65646
12         * pt.c (check_explicit_specialization): Don't
13         SET_DECL_TEMPLATE_SPECIALIZATION for a variable with no template
14         headers.
15         * decl.c (grokvardecl): Revert earlier fix.
17 2015-04-20  Paolo Carlini  <paolo.carlini@oracle.com>
19         PR c++/65801
20         * typeck2.c (check_narrowing): In C++11 mode too, -Wno-narrowing
21         suppresses the diagnostic.
23 2015-04-20  Ville Voutilainen  <ville.voutilainen@gmail.com>
25         Reject trailing return type for an operator auto().
26         * decl.c (grokdeclarator): Reject trailing return types for
27         all conversion operators, don't handle conversion operators
28         in the previous checks that deal with auto.
30 2015-04-20  Ilya Verbin  <ilya.verbin@intel.com>
32         * parser.c (cp_parser_omp_target_update): Add missed %> to error_at ().
34 2015-04-16  Paolo Carlini  <paolo.carlini@oracle.com>
36         * class.c (resolve_address_of_overloaded_function, instantiate_type):
37         Rename tsubst_flags_t parameter flags -> complain.
39 2015-04-16  Paolo Carlini  <paolo.carlini@oracle.com>
41         * call.c (build_op_delete_call, build_over_call): Check mark_used
42         return value.
43         * class.c (resolve_address_of_overloaded_function): Likewise.
44         * decl.c (cxx_maybe_build_cleanup): Likewise.
45         * pt.c (gen_elem_of_pack_expansion_instantiation, tsubst_baselink,
46         tsubst_qualified_id, tsubst_copy, tsubst_copy_and_build): Likewise.
47         * rtti.c (build_dynamic_cast_1): Likewise.
48         * semantics.c (process_outer_var_ref): Likewise.
49         * typeck.c (build_class_member_access_expr,
50         cp_build_function_call_vec, cp_build_addr_expr_1): Likewise.
52 2015-04-15  Jason Merrill  <jason@redhat.com>
54         * constexpr.c (cxx_eval_store_expression): Ignore clobbers.
55         (build_constexpr_constructor_member_initializers): Loop to find
56         the BIND_EXPR.
57         * decl.c (start_preparsed_function): Clobber the object at the
58         beginning of a constructor.
60         * decl.c (grokmethod): Only set DECL_COMDAT if TREE_PUBLIC is set.
61         * method.c (implicitly_declare_fn): Likewise.
62         * decl2.c (vague_linkage_p): Check TREE_PUBLIC first.
64         * decl2.c (determine_visibility): Use get_template_info.
66 2015-04-15  Jason Merrill  <jason@redhat.com>
67             Marek Polacek  <polacek@redhat.com>
69         PR c++/65727
70         * lambda.c (lambda_expr_this_capture): In unevaluated context go
71         through the normal loop, just don't capture.
72         (maybe_resolve_dummy): Handle null return.
74 2015-04-15  Paolo Carlini  <paolo.carlini@oracle.com>
76         * call.c (enforce_access): Emit error + inform.
78 2015-04-15  Marek Polacek  <polacek@redhat.com>
80         * constexpr.c (use_new_call): Remove #define.
81         (lookup_parameter_binding): Remove function.
82         (cxx_bind_parameters_in_call): Remove unused code.
83         (cxx_eval_call_expression): Likewise.
84         (cxx_eval_constant_expression): Likewise.
86 2015-04-14  Mikhail Maltsev  <maltsevm@gmail.com>
88         * tree.c (replace_placeholders_t): Remove unused type.
89         (replace_placeholders): Remove unused pset.
91 2015-04-14  Jason Merrill  <jason@redhat.com>
93         * pt.c (lookup_template_class_1): Use coerce_innermost_template_parms.
95         PR c++/65695
96         * cvt.c (cp_fold_convert): Avoid wrapping PTRMEM_CST in NOP_EXPR.
98         PR c++/65721
99         * name-lookup.c (do_class_using_decl): Complain about specifying
100         the current class even if there are dependent bases.
102 2015-04-14  David Krauss  <david_work@me.com>
104         PR c++/59766
105         * decl.c (grokdeclarator): Do not flag friends with deduced return.
107 2015-04-14  Momchil Velikov  <momchil.velikov@gmail.com>
108             Jason Merrill  <jason@redhat.com>
110         PR c++/60994
111         * parser.c (cp_parser_class_name): Add enum_ok parameter.
112         (cp_parser_qualifying_entity): Use it instead of cp_parser_type_name.
113         (cp_parser_diagnose_invalid_type_name): Don't assume a template is
114         a class template.
116 2015-04-12  Jakub Jelinek  <jakub@redhat.com>
118         PR c++/65736
119         * constexpr.c (cxx_eval_pointer_plus_expression): Don't fold for VLAs,
120         don't fold if op01 isn't divisible by TYPE_SIZE_UNIT.  Convert
121         the expression to the original type at the end.
123 2015-04-09  Jakub Jelinek  <jakub@redhat.com>
125         PR c++/65690
126         * tree.c (cp_build_qualified_type_real): Copy TYPE_ALIGN and
127         TYPE_USER_ALIGN.
129         PR c++/65690
130         * tree.c (build_cplus_array_type): Layout type before variants are
131         set, but copy over TYPE_SIZE and TYPE_SIZE_UNIT from the main
132         variant.
134 2015-04-03  Paolo Carlini  <paolo.carlini@oracle.com>
136         PR c++/64085
137         * lambda.c (add_capture): Use dependent_type_p for capture by
138         reference too.
140 2015-04-02  Marek Polacek  <polacek@redhat.com>
142         PR c++/65642
143         * constexpr.c (cxx_eval_pointer_plus_expression): Call
144         cxx_eval_constant_expression on the first operand.
146 2015-04-01  Jason Merrill  <jason@redhat.com>
148         PR c++/65625
149         * decl.c (make_typename_type): Handle seeing a variable template.
151 2015-04-01  Paolo Carlini  <paolo.carlini@oracle.com>
153         PR c++/56100
154         * pt.c (instantiating_current_function_p): New.
155         * name-lookup.c (pushdecl_maybe_friend_1): Use it.
156         * cp-tree.h (instantiating_current_function_p): Declare.
158 2015-04-01  Jason Merrill  <jason@redhat.com>
160         PR c++/65646
161         * decl.c (grokvardecl): Don't call check_explicit_specialization
162         for non-template members of a class template.
164 2015-04-01  Marek Polacek  <polacek@redhat.com>
166         PR c++/65554
167         * class.c (finish_struct): Require that the second field of a
168         user-defined initializer_list be of size type.
170 2015-03-31  Marek Polacek  <polacek@redhat.com>
172         PR c++/65390
173         * tree.c (build_cplus_array_type): Use dependent_type_p rather than
174         checking for constness.
176 2015-03-30  Marek Polacek  <polacek@redhat.com>
178         PR c++/65398
179         * constexpr.c (cxx_fold_indirect_ref): Don't perform the
180          *(&A[i] p+ j) => A[i + j] transformation here.
181         (cxx_eval_pointer_plus_expression): New function.
182         (cxx_eval_constant_expression): Use it here.
184 2015-03-27  Tobias Burnus  <burnus@net-b.de>
186         PR c/65586
187         * parser.c (cp_parser_omp_for, cp_parser_omp_parallel,
188         cp_parser_omp_distribute, cp_parser_omp_teams, cp_parser_omp_target,
189         cp_parser_omp_declare): Don't show error for skipped omp pragmas with
190         -fopenmp-simd.
192 2015-03-27  Marek Polacek  <polacek@redhat.com>
194         PR c++/65556
195         * semantics.c (finish_switch_cond): If the unlowered type is not an
196         enum, use the type of the condition.
198 2015-03-27  Jason Merrill  <jason@redhat.com>
200         PR c++/65509
201         * decl.c (make_rtl_for_nonlocal_decl): Don't defer static
202         constants.
204 2015-03-26  Mikhail Maltsev  <maltsevm@gmail.com>
206         PR c++/65154
207         * init.c (build_vec_init): Fix initializing aggregates
208         with empty init list.
210 2015-03-26  Jason Merrill  <jason@redhat.com>
212         PR c++/65525
213         * constexpr.c (potential_constant_expression_1): Handle MEM_REF.
215 2015-03-25  Marek Polacek  <polacek@redhat.com>
217         PR c++/65558
218         * name-lookup.c (handle_namespace_attrs): Ignore abi_tag attribute
219         on an anonymous namespace.
221 2015-03-25  Marek Polacek  <polacek@redhat.com>
223         PR c++/61670
224         * class.c (remove_zero_width_bit_fields): Check for null DECL_SIZE.
226 2015-03-24  Jason Merrill  <jason@redhat.com>
228         PR c++/65046
229         * cp-tree.h (NAMESPACE_IS_INLINE): Remove.
230         * parser.c (cp_parser_namespace_definition): Don't set it.
231         * name-lookup.c (handle_namespace_attrs): Check
232         DECL_NAMESPACE_ASSOCIATIONS instead.
234         PR c++/65498
235         * pt.c (get_mostly_instantiated_function_type): Just return the
236         type of the partially instantiated template in DECL_TI_TEMPLATE.
238 2015-03-20  Marek Polacek  <polacek@redhat.com>
240         PR c++/65398
241         * constexpr.c (cxx_fold_indirect_ref): Transform *(&A[i] p+ j) into
242         A[i + j].
244 2015-03-20  Marek Polacek  <polacek@redhat.com>
246         PR c++/65072
247         * typeck.c (lookup_anon_field): Make sure we're dealing with the main
248         variant.
250 2015-03-19  Jason Merrill  <jason@redhat.com>
252         PR c++/65046
253         Automatically propagate ABI tags to variables and functions
254         from their (return) type.
255         * class.c (check_tag): Handle variables and functions.
256         (mark_or_check_attr_tags): Split out from find_abi_tags_r.
257         (mark_or_check_tags): Likewise.
258         (mark_abi_tags): Use it.  Rename from mark_type_abi_tags.
259         (check_abi_tags): Add single argument overload for decls.
260         Handle inheriting tags for decls.
261         * mangle.c (write_mangled_name): Call it.
262         (mangle_return_type_p): Split out from write_encoding.
263         (unmangled_name_p): Split out from write_mangled_name.
264         (write_mangled_name): Ignore abi_tag on namespace.
265         * cp-tree.h (NAMESPACE_IS_INLINE): Replace NAMESPACE_ABI_TAG.
266         * parser.c (cp_parser_namespace_definition): Set it.
267         * name-lookup.c (handle_namespace_attrs): Use arguments. Warn
268         about abi_tag attribute on non-inline namespace.
269         * tree.c (check_abi_tag_args): Split out from handle_abi_tag_attribute.
270         (handle_abi_tag_attribute): Allow tags on variables.
272 2015-03-19  Jakub Jelinek  <jakub@redhat.com>
274         * decl2.c (cplus_decl_attributes): Also add "omp declare target"
275         attribute for DECL_EXTERNAL VAR_DECLs.
277 2015-03-18  Paolo Carlini  <paolo.carlini@oracle.com>
279         PR c++/65340
280         * call.c (build_over_call): Pass the tsubst_flags_t argument to
281         mark_used.
282         * decl2.c (mark_used): Inline the require_deduced_type call and
283         guard the error call.
285 2015-03-16  Jason Merrill  <jason@redhat.com>
287         PR c++/65061
288         * parser.c (cp_parser_template_name): Call strip_using_decl.
290 2015-03-16  Marek Polacek  <polacek@redhat.com>
292         DR 1688
293         PR c++/65327
294         * decl.c (grokdeclarator): Allow volatile and constexpr together.
296 2015-03-12  Paolo Carlini  <paolo.carlini@oracle.com>
298         PR c++/65323
299         * decl.c (check_default_argument): Don't call
300         maybe_warn_zero_as_null_pointer_constant.
302 2015-03-11  Aldy Hernandez  <aldyh@redhat.com>
304         * cp-gimplify.c (simple_empty_class_p): New.
305         * cp-gimplify.c (cp_gimplify_expr): Handle RETURN_EXPR.  Abstract
306         the code for empty class copies into simple_empty_class_p, and
307         adapt it to handle COMPOUND_EXPRs.
309 2015-03-10  Paolo Carlini  <paolo.carlini@oracle.com>
311         PR c++/65370
312         * decl.c (duplicate_decls): Call check_redeclaration_no_default_args
313         only if the location of newdecl doesn't match the location of olddecl.
315 2015-03-10  Jakub Jelinek  <jakub@redhat.com>
317         PR c++/65127
318         * parser.c (parsing_nsdmi): Don't return true if current_class_ptr
319         is not a PARM_DECL.
321 2015-03-10  Jason Merrill  <jason@redhat.com>
323         PR c++/65333
324         DR 1558
325         * pt.c (dependent_type_p_r): Check both class and alias template args.
327 2015-03-10  Jakub Jelinek  <jakub@redhat.com>
329         PR c/65120
330         * parser.c (cp_parser_binary_expression): Check for tcc_comparison
331         before preparing arguments to warn_logical_not_parentheses.
332         Use maybe_constant_value on rhs.
334 2015-03-09  Jason Merrill  <jason@redhat.com>
336         PR c++/65339
337         * call.c: Don't call maybe_resolve_dummy when calling a constructor.
339 2015-03-09  Jakub Jelinek  <jakub@redhat.com>
341         PR c/65120
342         * parser.c (cp_parser_binary_expression): Don't warn for
343         !!x == y or !b == y where b is bool.
345 2015-03-06  Aldy Hernandez  <aldyh@redhat.com>
347         * ptree.c (cxx_print_lambda_node): New.
348         (cxx_print_xnode): Handle LAMBDA_EXPR.
350 2015-03-03  Aldy Hernandez  <aldyh@redhat.com>
352         PR c++/65295
353         * constexpr.c (cxx_eval_constant_expression): Remove assert in
354         RESULT_DECL handling.
356 2015-02-26  Marek Polacek  <polacek@redhat.com>
358         PR c++/65202
359         * constexpr.c (cxx_eval_constant_expression): Don't evaluate
360         a RETURN_EXPR if its operand is null.
362 2015-02-25  Jason Merrill  <jason@redhat.com>
364         PR c++/65209
365         * decl2.c (constrain_visibility) [VISIBILITY_ANON]: Clear
366         DECL_COMDAT.
367         (constrain_visibility_for_template): Handle reference arguments.
369         PR debug/58315
370         * decl.c (start_preparsed_function): Use create_artificial_label
371         for cdtor_label.
373 2015-02-17  Paolo Carlini  <paolo.carlini@oracle.com>
374             Jakub Jelinek  <jakub@redhat.com>
376         PR c++/65075
377         * constexpr.c (check_constexpr_bind_expr_vars): Allow
378         implicit typedefs for lambda types.
380 2015-02-13  Paolo Carlini  <paolo.carlini@oracle.com>
382         PR c++/60894
383         * decl.c (lookup_and_check_tag): Use strip_using_decl.
385 2015-02-13  Jason Merrill  <jason@redhat.com>
387         PR c++/65054
388         * pt.c (template_args_equal): Look through conversions here.
389         * tree.c (cp_tree_equal): Not here.
391 2015-02-13  Paolo Carlini  <paolo.carlini@oracle.com>
393         PR c++/60211
394         * parser.c (cp_parser_pragma): Diagnose PRAGMA_IVDEP at
395         pragma_external context.
397 2015-02-13  Jason Merrill  <jason@redhat.com>
399         PR c++/65051
400         * call.c (reference_binding): Don't look for bad conversion
401         if TO is incomplete.
403 2015-02-13  Paolo Carlini  <paolo.carlini@oracle.com>
405         PR c++/64970
406         * decl.c (make_typename_type): Pass tsubst_flags_t argument
407         to lookup_template_class.
409 2015-02-13  Jakub Jelinek  <jakub@redhat.com>
411         PR ipa/65034
412         * decl.c (start_preparsed_function): Use void_type_node instead
413         of NULL_TREE as LABEL_DECL type.
415 2015-02-12  Jason Merrill  <jason@redhat.com>
417         PR c++/64898
418         * mangle.c (write_mangled_name): Fix test for variable template
419         instantiation.
421         * decl.c (begin_destructor_body): Condition clobber on
422         -flifetime-dse.
424 2015-02-12 Andrea Azzarone <azzaronea@gmail.com>
426         PR c++/64959
427         * parser.c (lookup_literal_operator): Return all candidates.
428         (cp_parser_userdef_char_literal): Simplify error handling.
429         (cp_parser_userdef_numeric_literal):  Pass tf_warning_or_error.
430         (cp_parser_userdef_string_literal): Pass tf_warning_or_error.
431         Also give higher priority to standard string UDL operator.
433 2015-02-12  Jakub Jelinek  <jakub@redhat.com>
435         PR debug/55541
436         * cp-tree.h (BLOCK_OUTER_CURLY_BRACE_P): Define.
437         * decl.c (poplevel): If functionbody, try not to create an extra
438         BLOCK for function body and use subblocks as that, if it is non-NULL
439         and doesn't have siblings.  Set BLOCK_OUTER_CURLY_BRACE_P flag.
440         (outer_curly_brace_block): Use BLOCK_OUTER_CURLY_BRACE_P flag.
442         PR sanitizer/64984
443         * except.c (check_noexcept_r): Return NULL for internal
444         calls.
446 2015-02-10  Jason Merrill  <jason@redhat.com>
448         PR c++/64994
449         * constexpr.c (cxx_eval_call_expression): Walk the clone list.
451 2015-02-10  Jan Hubicka  <hubicka@ucw.cz>
453         PR ipa/64982
454         * method.c (use_thunk): Do not check for stdarg thunks.
456 2015-02-06  Jason Merrill  <jason@redhat.com>
458         PR c++/64899
459         * init.c (build_vec_init): Handle default-initialized array with
460         constexpr default constructor.
462 2015-02-04  Jakub Jelinek  <jakub@redhat.com>
464         PR c/64824
465         PR c/64868
466         * parser.c (cp_parser_omp_atomic): Handle RDIV_EXPR.
468 2015-02-03  Paolo Carlini  <paolo.carlini@oracle.com>
470         PR c++/64877
471         * typeck.c (cp_build_binary_op): Avoid spurious -Waddress warnings
472         for generated expressions.
474 2015-02-02  Ville Voutilainen  <ville.voutilainen@gmail.com>
476         PR c++/64901
477         * decl.c (duplicate_decls): Also duplicate DECL_FINAL_P and
478         DECL_OVERRIDE_P.
480 2015-02-02  Jason Merrill  <jason@redhat.com>
482         * tree.c (handle_abi_tag_attribute): Diagnose invalid arguments.
484 2015-01-30  Joseph Myers  <joseph@codesourcery.com>
486         * class.c, except.c, parser.c, pt.c: All callers of fatal_error
487         changed to pass input_location as first argument.
489 2015-01-29  Jakub Jelinek  <jakub@redhat.com>
491         PR c++/64717
492         * cp-ubsan.c (cp_ubsan_instrument_vptr): Don't wrap vptr
493         into SAVE_EXPR.
495 2015-01-29  Jason Merrill  <jason@redhat.com>
497         PR c++/49508
498         * semantics.c (finish_return_stmt): Suppress -Wreturn-type on
499         erroneous return statement.
501         PR c++/64521
502         * repo.c (repo_emit_p): It's OK for a clone to be extern at this
503         point.
505 2015-01-27  Caroline Tice  <cmtice@google.com>
507         Committing VTV Cywin/Ming patch for Patrick Wollgast
508         * vtable-class-hierarchy.cc (vtv_generate_init_routine): Add
509         check for not TARGET_PECOFF at the VTV_PREINIT_PRIORITY checks.
511 2015-01-27  Jason Merrill  <jason@redhat.com>
513         PR c++/58597
514         * lambda.c (maybe_add_lambda_conv_op): Check cfun rather than
515         current_function_decl.
517         PR c++/63889
518         * pt.c (finish_template_variable): Move from semantics.c.
519         Handle multiple template arg levels.  Handle coercion here.
520         (lookup_template_variable): Not here.
522 2015-01-23  Jason Merrill  <jason@redhat.com>
524         PR c++/64314
525         PR c++/57510
526         * typeck2.c (split_nonconstant_init_1): Remove a sub-CONSTRUCTOR
527         that has been completely split out.
529         PR c++/64701
530         * constexpr.c (cxx_eval_constant_expression): Don't crash on C++
531         statement codes.
533         PR c++/64727
534         * constexpr.c (cxx_eval_constant_expression): Allow for lvalue use
535         of CONST_DECL.
537 2015-01-21  Jason Merrill  <jason@redhat.com>
539         PR c++/64603
540         * constexpr.c (cxx_eval_constant_expression): Only shortcut
541         constant CONSTRUCTORs.
543         PR c++/64647
544         * constexpr.c (ensure_literal_type_for_constexpr_object): Don't
545         give a hard error in a template instantiation.
547 2015-01-21  Richard Biener  <rguenther@suse.de>
549         PR middle-end/64313
550         * decl.c (duplicate_decls): Call set_builtin_decl_declared_p
551         for builtins the user declared correctly.
553 2015-01-16  Paolo Carlini  <paolo.carlini@oracle.com>
555         PR c++/58614
556         * pt.c (unify): When BRACE_ENCLOSED_INITIALIZER_P (arg), handle
557         TREE_TYPE (elt) == error_mark_node.
559 2015-01-15  Jan Hubicka  <hubicka@ucw.cz>
561         PR tree-optimization/62053
562         * tree.c (build_cplus_array_type): Layout type after variants are set.
564 2015-01-15  Jakub Jelinek  <jakub@redhat.com>
566         * cp-gimplify.c (cp_genericize_r): Call
567         cp_ubsan_maybe_instrument_member_call for member calls.
568         (cp_ubsan_check_member_access_r): New function.
569         (cp_genericize_tree): Call cp_ubsan_instrument_member_accesses.
570         * cp-tree.h (cp_ubsan_maybe_instrument_member_call,
571         cp_ubsan_instrument_member_accesses,
572         cp_ubsan_maybe_instrument_downcast,
573         cp_ubsan_maybe_instrument_cast_to_vbase): New prototypes.
574         * cp-ubsan.c: New file.
575         * Make-lang.in (CXX_AND_OBJCXX_OBJS): Add cp/cp-ubsan.o.
576         * constexpr.c (cxx_eval_call_expression): Return void_node
577         for IFN_UBSAN_VPTR.
578         (potential_constant_expression_1): Return true for
579         UBSAN_NULL, UBSAN_BOUNDS and UBSAN_VPTR internal calls.
580         * typeck.c (build_class_member_access_expr): Provide locus
581         for COMPONENT_REFs.
582         (build_static_cast_1): Instrument downcasts.
583         * class.c (build_base_path): For -fsanitize=vptr and !fixed_type_p
584         add ubsan instrumentation for virtual_access.
585         * call.c: Include internal-fn.h.
586         (set_flags_from_callee): Handle internal calls.
588 2015-01-15  Momchil Velikov  <momchil.velikov@gmail.com>
590         PR c++/59366
591         * name-lookup.c (pushdecl_maybe_friend_1): Hide friend functions
592         and function templates, declared only in the class.
593         * decl.c (duplicate_decls): Reveal hidden friend functions or
594         function templates, if they are redeclared outside the class.
596 2015-01-15  Jason Merrill  <jason@redhat.com>
598         PR c++/64356
599         * constexpr.c (cxx_eval_binary_expression): Fix pasto.
601         PR c++/63283
602         * constexpr.c (potential_constant_expression_1): Handle reference
603         args in templates.
605 2015-01-15  Thomas Schwinge  <thomas@codesourcery.com>
606             James Norris  <jnorris@codesourcery.com>
607             Cesar Philippidis  <cesar@codesourcery.com>
608             Ilmir Usmanov  <i.usmanov@samsung.com>
609             Jakub Jelinek  <jakub@redhat.com>
611         * parser.c: Include "gomp-constants.h".
612         (cp_parser_omp_clause_map): Use enum gomp_map_kind instead of enum
613         omp_clause_map_kind.  Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
614         Use OMP_CLAUSE_SET_MAP_KIND.
615         (cp_parser_omp_construct, cp_parser_pragma): Handle
616         PRAGMA_OACC_CACHE, PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA,
617         PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_PARALLEL,
618         PRAGMA_OACC_LOOP, PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
619         (cp_parser_omp_clause_name): Handle "async", "copy", "copyout",
620         "create", "delete", "deviceptr", "host", "num_gangs",
621         "num_workers", "present", "present_or_copy", "pcopy",
622         "present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout",
623         "present_or_create", "pcreate", "vector_length", "wait".
624         (OACC_DATA_CLAUSE_MASK, OACC_ENTER_DATA_CLAUSE_MASK)
625         (OACC_EXIT_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
626         (OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK)
627         (OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros.
628         (cp_parser_omp_var_list_no_open): Handle OMP_CLAUSE__CACHE_.
629         (cp_parser_oacc_data_clause, cp_parser_oacc_data_clause_deviceptr)
630         (cp_parser_oacc_clause_vector_length, cp_parser_oacc_wait_list)
631         (cp_parser_oacc_clause_wait, cp_parser_omp_clause_num_gangs)
632         (cp_parser_omp_clause_num_workers, cp_parser_oacc_clause_async)
633         (cp_parser_oacc_all_clauses, cp_parser_oacc_cache)
634         (cp_parser_oacc_data, cp_parser_oacc_enter_exit_data)
635         (cp_parser_oacc_kernels, cp_parser_oacc_loop)
636         (cp_parser_oacc_parallel, cp_parser_oacc_update)
637         (cp_parser_oacc_wait): New functions.
638         * cp-tree.h (finish_oacc_data, finish_oacc_kernels)
639         (finish_oacc_parallel): New prototypes.
640         * semantics.c: Include "gomp-constants.h".
641         (handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR.  Use
642         GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.  Use
643         OMP_CLAUSE_SET_MAP_KIND.
644         (finish_omp_clauses): Handle OMP_CLAUSE_ASYNC,
645         OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_WAIT, OMP_CLAUSE__CACHE_.
646         Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
647         (finish_oacc_data, finish_oacc_kernels, finish_oacc_parallel): New
648         functions.
650 2015-01-14  Paolo Carlini  <paolo.carlini@oracle.com>
652         PR c++/58671
653         * decl2.c (var_defined_without_dynamic_init): Handle gracefully
654         self-initialization.
656 2015-01-13  Jason Merrill  <jason@redhat.com>
658         PR c++/64356
659         PR libstdc++/58777
660         * constexpr.c (cxx_eval_binary_expression): Don't VERIFY_CONSTANT
661         pointer expressions.
662         (cxx_eval_increment_expression): Likewise.
664         PR c++/64514
665         * pt.c (coerce_template_parameter_pack): Return NULL for a
666         zero-length fixed parameter pack with a pack expansion arg.
668         PR c++/64520
669         * pt.c (unify): Don't try to deduce to std::initializer_list<T...>.
671 2015-01-12  Jason Merrill  <jason@redhat.com>
673         PR c++/64547
674         * constexpr.c (cxx_eval_call_expression): A call to a void
675         function doesn't need to return a value.
677 2015-01-09  Michael Collison  <michael.collison@linaro.org>
679         * call.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
680         input.h, alias.h, symtab.h, options.h, fold-const.h,
681         wide-int.h, and inchash.h due to flattening of tree.h.
682         * class.c: Ditto.
683         * constexpr.c: Ditto.
684         * cp-array-notation.c: Ditto.
685         * cp-gimplify.c: Ditto.
686         * cp-lang.c: Ditto.
687         * cp-objcp-common.c: Ditto.
688         * cvt.c: Ditto.
689         * decl2.c: Ditto.
690         * decl.c: Ditto.
691         * dump.c: Ditto.
692         * error.c: Ditto.
693         * except.c: Ditto.
694         * expr.c: Ditto.
695         * friend.c: Ditto.
696         * init.c: Ditto.
697         * lambda.c: Ditto.
698         * lex.c: Ditto.
699         * mangle.c: Ditto.
700         * name-lookup.c: Ditto.
701         * optimize.c: Ditto.
702         * parser.c: Ditto.
703         * pt.c: Ditto.
704         * ptree.c: Ditto.
705         * repo.c: Ditto.
706         * rtti.c: Ditto.
707         * search.c: Ditto.
708         * semantics.c: Ditto.
709         * tree.c: Ditto.
710         * typeck2.c: Ditto.
711         * typeck.c: Ditto.
713 2015-01-08  Jason Merrill  <jason@redhat.com>
715         * cp-gimplify.c (cp_genericize): Use do_ubsan_in_current_function.
716         * decl.c (compute_array_index_type): Likewise.
717         * init.c (build_vec_init): Likewise.
718         * typeck.c (cp_build_binary_op): Likewise.
720 2015-01-08  Jason Merrill  <jason@redhat.com>
722         * init.c (build_vec_init): Call ubsan_instrument_bounds to check
723         whether an initializer-list is too big for a VLA.
724         (throw_bad_array_length): Remove.
725         * cp-tree.h: Remove prototype.
727 2015-01-08  Paolo Carlini  <paolo.carlini@oracle.com>
729         PR c++/60753
730         * decl.c (grokfndecl): Add bool parameter.
731         (grokdeclarator): Adjust calls.
732         (start_decl): Don't set DECL_DELETED_FN here.
734 2015-01-06  Jason Merrill  <jason@redhat.com>
736         * parser.c (cp_parser_nested_name_specifier_opt): Diagnose invalid
737         template-ids.
739         PR c++/64455
740         * pt.c (type_dependent_expression_p): Handle variable templates.
741         * constexpr.c (potential_constant_expression_1): Use it.
743         PR c++/64487
744         * semantics.c (finish_offsetof): Handle templates here.
745         * parser.c (cp_parser_builtin_offsetof): Not here.
747         PR c++/64496
748         * semantics.c (process_outer_var_ref): Diagnose lambda in local
749         class NSDMI.
751 2015-01-06  Ville Voutilainen  <ville.voutilainen@gmail.com>
753         PR c++/64489
754         * class.c (check_field_decls): Make copy assignment operators
755         complex only in c++98 mode.
757 2015-01-05  Trevor Saunders  <tsaunders@mozilla.com>
759         PR c++/31397
760         * class.c (check_for_override): Warn when a virtual function is an
761         override not marked override.
763 2015-01-05  Trevor Saunders  <tsaunders@mozilla.com>
765         * class.c (warn_hidden): Use auto_vec<tree> instead of tree_list to
766         hold base_fndecls.
767         (get_basefndecls): Adjust.
769 2015-01-05  Jakub Jelinek  <jakub@redhat.com>
771         Update copyright years.
773 2015-01-05  Marek Polacek  <polacek@redhat.com>
775         PR c/64423
776         * typeck.c (cp_build_array_ref): Pass loc down to
777         warn_array_subscript_with_type_char.
780 Copyright (C) 2015 Free Software Foundation, Inc.
782 Copying and distribution of this file, with or without modification,
783 are permitted in any medium without royalty provided the copyright
784 notice and this notice are preserved.