blob: 7b13865233b84ccb869714380372effc735ced5b [file] [log] [blame]
2017-10-10 Release Manager
* GCC 5.5.0 released.
2017-09-18 Jason Merrill <jason@redhat.com>
PR c++/80294 - ICE with constexpr and inheritance.
* constexpr.c (reduced_constant_expression_p):
A null constructor element is non-constant.
(cxx_eval_indirect_ref): Don't VERIFY_CONSTANT before
returning an empty base.
PR c++/79607 - ICE with T{} initializer
* decl.c (type_dependent_init_p): Check the type of a CONSTRUCTOR.
PR c++/72457
* init.c (expand_aggr_init_1): Only handle value-init of bases.
* constexpr.c (build_data_member_initialization): Handle multiple
initializers for the same field.
PR c++/55922
PR c++/63151
* init.c (expand_aggr_init_1): Handle list-initialization from {}.
2017-09-16 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2017-06-21 Jakub Jelinek <jakub@redhat.com>
PR c++/81154
* semantics.c (handle_omp_array_sections_1, finish_omp_clauses):
Complain about t not being a variable if t is OVERLOAD even
when processing_template_decl.
2017-06-13 Jakub Jelinek <jakub@redhat.com>
PR c++/80984
* cp-gimplify.c (cp_genericize): Only look for VAR_DECLs in
BLOCK_VARS (outer) chain.
(cxx_omp_const_qual_no_mutable): Likewise.
2017-06-08 Jakub Jelinek <jakub@redhat.com>
PR c/81006
* semantics.c (handle_omp_array_sections_1): Convert TYPE_MAX_VALUE
to sizetype before size_binop.
2017-05-30 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2017-04-11 Jakub Jelinek <jakub@redhat.com>
PR c++/80363
* error.c (dump_expr): Handle VEC_COND_EXPR like COND_EXPR.
2017-04-10 Jakub Jelinek <jakub@redhat.com>
PR c++/80176
* tree.c (lvalue_kind): For COMPONENT_REF with BASELINK second
operand, if it is a static member function, recurse on the
BASELINK.
2017-03-22 Jakub Jelinek <jakub@redhat.com>
PR c++/80141
* semantics.c (finish_omp_clause) <case OMP_CLAUSE_SIMDLEN,
case OMP_CLAUSE_ALIGNED>: Call maybe_constant_value only when not
processing_template_decl.
2017-03-10 Jakub Jelinek <jakub@redhat.com>
PR c++/79896
* decl.c (finish_enum_value_list): If value is error_mark_node,
don't copy it and change its type.
* init.c (constant_value_1): Return error_mark_node if DECL_INITIAL
of CONST_DECL is error_mark_node.
2017-02-22 Jakub Jelinek <jakub@redhat.com>
PR c++/79664
* parser.c (cp_parser_omp_teams, cp_parser_omp_target): Use
SET_EXPR_LOCATION on OMP_TARGET/OMP_TEAMS tree.
* constexpr.c (potential_constant_expression_1): Handle
OMP_*, OACC_* and CILK_* trees.
2017-02-16 Jakub Jelinek <jakub@redhat.com>
PR c++/79512
* parser.c (cp_parser_omp_target): For -fopenmp-simd
ignore #pragma omp target even when not followed by identifier.
2017-01-11 Jakub Jelinek <jakub@redhat.com>
PR c++/78341
* parser.c (cp_parser_std_attribute_spec): Remove over-eager
assertion. Formatting fix.
2017-01-04 Jakub Jelinek <jakub@redhat.com>
PR c++/78949
* typeck.c (cp_build_unary_op): Call mark_rvalue_use on arg if it has
vector type.
2016-12-02 Jakub Jelinek <jakub@redhat.com>
PR c++/78649
* pt.c (tsubst_init): Don't call build_value_init if decl's type
is error_mark_node.
2016-11-23 Jakub Jelinek <jakub@redhat.com>
PR c++/77739
* cp-gimplify.c (cp_gimplify_tree) <case VEC_INIT_EXPR>: Pass
false as handle_invisiref_parm_p to cp_genericize_tree.
(struct cp_genericize_data): Add handle_invisiref_parm_p field.
(cp_genericize_r): Don't wrap is_invisiref_parm into references
if !wtd->handle_invisiref_parm_p.
(cp_genericize_tree): Add handle_invisiref_parm_p argument,
set wtd.handle_invisiref_parm_p to it.
(cp_genericize): Pass true as handle_invisiref_parm_p to
cp_genericize_tree. Formatting fix.
2016-11-18 Jakub Jelinek <jakub@redhat.com>
PR c++/77285
* mangle.c (mangle_tls_init_fn, mangle_tls_wrapper_fn): Call
check_abi_tags.
2016-10-31 Jakub Jelinek <jakub@redhat.com>
PR c++/78089
* parser.c (cp_parser_postfix_expression): Replace return statement in
the first switch with setting postfix_expression to the return
expression and break;.
2016-09-28 Jakub Jelinek <jakub@redhat.com>
PR c++/77467
* constexpr.c (enum constexpr_switch_state): New.
(struct constexpr_ctx): Add css_state field.
(label_matches): Add CTX and STMT arguments, remove I and
DEFAULT_LABEL. For CASE_LABEL_EXPR assert ctx->css_state != NULL,
handle default labels according to css_state.
(cxx_eval_statement_list): Remove statement skipping, label_matches
and default_label handling code.
(cxx_eval_loop_expr): Exit after first iteration even if
switches (jump_target).
(cxx_eval_switch_expr): Set up css_state field in ctx, if default
label has been seen in the body, but no cases matched, evaluate
the body second time.
(cxx_eval_constant_expression): Handle stmt skipping and label_matches
here. Handle PREDICT_EXPR. For MODIFY_EXPR or INIT_EXPR, assert
statement is not skipped. For COND_EXPR during skipping, don't
evaluate condition, just the then block and if still skipping at the
end also the else block.
(cxx_eval_outermost_constant_expr): Adjust constexpr_ctx initializer.
(is_sub_constant_expr): Likewise.
2016-09-27 Jakub Jelinek <jakub@redhat.com>
PR c++/77722
* cp-gimplify.c (cp_ubsan_maybe_instrument_return): Instrument also
functions that have just a STATEMENT_LIST instead of BIND_EXPR, or
BIND_EXPR with some statement rather than STATEMENT_LIST as body.
2016-09-20 Jakub Jelinek <jakub@redhat.com>
PR c++/77637
* parser.c (cp_parser_std_attribute_list): Reject ... without
preceding attribute.
2016-09-16 Jakub Jelinek <jakub@redhat.com>
PR c++/77375
* class.c (check_bases): Set CLASSTYPE_HAS_MUTABLE if any
TYPE_HAS_MUTABLE_P for any bases.
2016-08-11 Jakub Jelinek <jakub@redhat.com>
PR c++/72868
* constexpr.c (label_matches): Handle case range expressions.
2017-01-12 Nathan Sidwell <nathan@acm.org>
PR c++/77812
* name-lookup.c (set_namespace_binding_1): An overload of 1 decl
is a new overload.
2016-12-08 Nathan Sidwell <nathan@acm.org>
PR c++/78551
* constexpr.c (extract_string_elt): New. Broken out of ...
(cxx_eval_array_reference): ... here. Call it.
(cxx_eval_store_expression): Convert init by STRING_CST into
CONSTRUCTOR, if needed.
2016-08-05 Nathan Sidwell <nathan@acm.org>
PR c++/68724
* pt.c (unify): TRAIT_EXPR is an expr.
2016-07-25 Jason Merrill <jason@redhat.com>
PR c++/71833
* pt.c (coerce_template_parameter_pack): Fix logic for
pack index.
2016-07-21 Jason Merrill <jason@redhat.com>
PR c++/69223
* semantics.c (apply_deduced_return_type): Call
complete_type_or_else before building the new RESULT_DECL.
PR c++/71630
* pt.c (instantiate_decl): Fix pattern_defined for namespace scope
variable templates.
PR c++/71913
* call.c (unsafe_copy_elision_p): It's OK to elide when
initializing an unknown object.
2016-07-20 Jakub Jelinek <jakub@redhat.com>
PR c++/71909
* parser.c (cp_parser_save_member_function_body): Consume
__transaction_relaxed or __transaction_atomic with optional
attribute. Only skip catch with block if try keyword is seen.
2016-07-19 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2016-07-18 Jakub Jelinek <jakub@redhat.com>
PR c++/71871
* typeck.c (build_x_conditional_expr): Revert the 2012-10-25 change.
2016-07-07 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2016-06-14 Jakub Jelinek <jakub@redhat.com>
PR c++/71528
* decl.c (duplicate_decls): For DECL_INITIALIZED_P non-external
olddecl vars, preserve their TREE_READONLY bit.
PR c++/71516
* decl.c (complete_vars): Handle gracefully type == error_mark_node.
2016-06-08 Jakub Jelinek <jakub@redhat.com>
PR c++/71442
* pt.c (tsubst_copy): Only set TREE_USED on DECLs.
2016-06-03 Release Manager
* GCC 5.4.0 released.
2016-05-23 Richard Biener <rguenther@suse.de>
Backport from mainline
2016-03-23 Patrick Palka <ppalka@gcc.gnu.org>
PR c++/70347
* typeck.c (process_init_constructor_union): If the initializer
is empty, use the union's NSDMI if it has one.
2016-05-20 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/70466
* call.c (convert_like_real): Check that we are actually converting
from an init list.
2016-05-18 Jason Merrill <jason@redhat.com>
PR c++/70505
* pt.c (tsubst_baselink): Give the new TEMPLATE_ID_EXPR
unknown_type_node, too.
PR c++/70494
* decl.c (cxx_maybe_build_cleanup): Handle non-decls.
* typeck2.c (split_nonconstant_init_1): Use it.
PR c++/70648
* constexpr.c (cxx_eval_store_expression): Also copy
CONSTRUCTOR_NO_IMPLICIT_ZERO.
PR c++/70353
* decl.c (make_rtl_for_nonlocal_decl): Don't defer local statics
in constexpr functions.
PR c++/70095
* pt.c (instantiate_decl): Fix call to variable_template_p.
2016-05-18 Jason Merrill <jason@redhat.com>
Jakub Jelinek <jakub@redhat.com>
PR c++/70135
* constexpr.c (struct constexpr_ctx): Add save_exprs field.
(cxx_eval_loop_expr): Discard SAVE_EXPR values before looping.
(cxx_eval_constant_expression) [SAVE_EXPR]: Add it to the set.
(cxx_eval_outermost_constant_expr, is_sub_constant_expr): Initialize.
2016-05-18 Jason Merrill <jason@redhat.com>
* method.c (synthesized_method_walk): operator= can also be constexpr.
2016-05-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/70635
* pt.c (resolve_typename_type): Fix typos in infinite recursion
avoidance mechanism.
2016-04-18 Marek Polacek <polacek@redhat.com>
Backport from mainline
2016-03-31 Marek Polacek <polacek@redhat.com>
PR c/70297
* decl.c (duplicate_decls): Also set TYPE_ALIGN and TYPE_USER_ALIGN.
2016-04-18 Marek Polacek <polacek@redhat.com>
Backport from mainline
2015-11-11 Jason Merrill <jason@redhat.com>
* decl.c (duplicate_decls): When combining typedefs, remove the
new type from the variants list.
2016-04-15 Jason Merrill <jason@redhat.com>
* pt.c (tsubst_copy_and_build) [LAMBDA_EXPR]: Get
LAMBDA_EXPR_RETURN_TYPE from the instantiated closure.
PR c++/67164
* pt.c (copy_template_args): New.
(tsubst_pack_expansion): Use it.
2016-04-13 Alan Modra <amodra@gmail.com>
Backport from mainline
2016-03-22 Patrick Palka <ppalka@gcc.gnu.org>
PR target/70107
PR c++/70096
* pt.c (tsubst_decl): Clear the DECL_MODE of the new decl.
2016-04-06 Richard Biener <rguenther@suse.de>
Backport from mainline
2016-03-31 Richard Biener <rguenther@suse.de>
PR c++/70430
* typeck.c (cp_build_binary_op): Fix operand order of vector
conditional in truth op handling.
2016-03-31 Nathan Sidwell <nathan@acm.org>
PR c++/70393
* constexpr.c (cxx_eval_store_expression): Keep CONSTRUCTOR
elements in field order.
2016-03-30 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2016-03-17 Jakub Jelinek <jakub@redhat.com>
PR c++/70272
* decl.c (begin_destructor_body): Don't insert clobber if
is_empty_class (current_class_type).
2016-02-19 Jakub Jelinek <jakub@redhat.com>
PR c++/67767
* parser.c (cp_parser_std_attribute_spec_seq): Don't assume
attr_spec is always single element chain, chain all the attributes
properly together in the right order.
2016-03-21 Marek Polacek <polacek@redhat.com>
Backported from mainline
2016-03-15 Marek Polacek <polacek@redhat.com>
PR c++/70209
* tree.c (strip_typedefs): Call strip_typedefs again on the
DECL_ORIGINAL_TYPE result.
2016-03-18 Jason Merrill <jason@redhat.com>
PR c++/70139
* constexpr.c (cxx_eval_call_expression): Don't shortcut trivial copy.
2016-03-05 Jason Merrill <jason@redhat.com>
PR c++/67364
* constexpr.c (cxx_eval_store_expression): Replace
CONSTRUCTOR_ELTS in nested CONSTRUCTORs, too.
2016-03-04 Jason Merrill <jason@redhat.com>
PR c++/67364
* constexpr.c (cxx_eval_component_reference): Further tweak.
PR c++/70067
* tree.c (strip_typedefs): Handle TYPENAME_TYPE lookup finding the
same type.
2016-03-03 Jason Merrill <jason@redhat.com>
* call.c (build_aggr_conv): Use get_nsdmi.
PR c++/51406
* typeck.c (build_static_cast_1): Avoid folding back to lvalue.
PR c++/67364
* constexpr.c (cxx_eval_component_reference): Just return an empty
CONSTRUCTOR for an empty class.
2016-03-01 Paolo Carlini <paolo.carlini@oracle.com>
* call.c (build_op_delete_call, build_over_call): Check mark_used
return value.
* class.c (resolve_address_of_overloaded_function): Likewise.
* decl.c (cxx_maybe_build_cleanup): Likewise.
* pt.c (gen_elem_of_pack_expansion_instantiation, tsubst_baselink,
tsubst_qualified_id, tsubst_copy, tsubst_copy_and_build): Likewise.
* rtti.c (build_dynamic_cast_1): Likewise.
* semantics.c (process_outer_var_ref): Likewise.
* typeck.c (build_class_member_access_expr,
cp_build_function_call_vec, cp_build_addr_expr_1): Likewise.
2016-03-01 Jason Merrill <jason@redhat.com>
PR c++/69261
* constexpr.c (find_array_ctor_elt): Handle splitting RANGE_EXPR.
2016-03-01 Markus Trippelsdorf <markus@trippelsdorf.de>
Paolo Carlini <paolo.carlini@oracle.com>
PR c++/68087
* constexpr.c (cxx_eval_array_reference): Use tree_fits_shwi_p before
tree_to_shwi to avoid ICEs.
2016-03-01 Jason Merrill <jason@redhat.com>
PR c++/67104
* constexpr.c (array_index_cmp, find_array_ctor_elt): New.
(cxx_eval_array_reference, cxx_eval_store_expression): Use them.
PR c++/51489
* constexpr.c (cxx_eval_binary_expression): Don't VERIFY_CONSTANT
the operands.
PR c++/69995
* constexpr.c (cxx_eval_call_expression): Unshare arg.
(cxx_eval_constant_expression) [DECL_EXPR]: Unshare init.
[TARGET_EXPR]: Unshare init.
2016-02-29 Jason Merrill <jason@redhat.com>
PR c++/69995
* constexpr.c (cxx_eval_store_expression): Unshare init.
PR c++/65985
* constexpr.c (build_constexpr_constructor_member_initializers):
Handle an additional STATEMENT_LIST.
2016-02-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
Backported from mainline
2016-02-19 Jakub Jelinek <jakub@redhat.com>
Bernd Edlinger <bernd.edlinger@hotmail.de>
* Make-lang.in: Invoke gperf with -L C++.
* cfns.gperf: Remove prototypes for hash and libc_name_p
inlines.
* cfns.h: Regenerated.
* except.c (nothrow_libfn_p): Adjust.
2016-02-25 Jason Merrill <jason@redhat.com>
PR c++/67364
* constexpr.c (cxx_eval_component_reference): Don't complain about
unevaluated empty classes.
PR c++/68049
* tree.c (strip_typedefs): Use DECL_ORIGINAL_TYPE.
2016-02-24 Jason Merrill <jason@redhat.com>
PR c++/69323
* pt.c (instantiate_class_template_1): Set
processing_template_decl before substituting friend_type.
2016-02-19 Jason Merrill <jason@redhat.com>
PR c++/69743
* call.c (remaining_arguments): No longer static.
* cp-tree.h: Declare it.
* pt.c (more_specialized_fn): Use it.
2016-02-17 Jason Merrill <jason@redhat.com>
PR c++/68585
* constexpr.c (cxx_eval_bare_aggregate): Fix 'changed' detection.
PR c++/68679
* decl2.c (reset_type_linkage_2): Look through member templates.
2016-02-15 Jason Merrill <jason@redhat.com>
PR c++/68890
* constexpr.c (verify_ctor_sanity): Remove CONSTRUCTOR_NELTS check.
2016-02-10 Jason Merrill <jason@redhat.com>
PR c++/68926
* pt.c (resolve_nondeduced_context): Add complain parm.
(do_auto_deduction): Pass it.
* cvt.c (convert_to_void): Likewise.
* decl.c (cp_finish_decl): Likewise.
* init.c (build_new): Likewise.
* rtti.c (get_tinfo_decl_dynamic): Likewise.
* semantics.c (finish_decltype_type): Likewise.
* typeck.c (decay_conversion): Likewise.
* cp-tree.h: Adjust declaration.
* call.c (standard_conversion): Add complain parm, pass it along.
(implicit_conversion): Pass it.
2016-02-10 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2016-02-08 Jakub Jelinek <jakub@redhat.com>
PR c++/59627
* parser.c (cp_parser_omp_declare_reduction): Set assembler name
of the DECL_OMP_DECLARE_REDUCTION_P decls.
2016-01-31 Jason Merrill <jason@redhat.com>
PR c++/69009
* pt.c (partial_specialization_p, impartial_args): New.
(instantiate_decl): Call impartial_args.
2016-01-27 Marek Polacek <polacek@redhat.com>
Backport from mainline
2016-01-27 Marek Polacek <polacek@redhat.com>
PR c/68062
* typeck.c (cp_build_binary_op): Promote operand to unsigned, if
needed. Add -Wsign-compare warning.
2016-01-27 Jason Merrill <jason@redhat.com>
PR c++/68949
* optimize.c (maybe_clone_body): Clear DECL_SAVED_TREE of the alias.
* semantics.c (expand_or_defer_fn_1): Keep DECL_SAVED_TREE of
maybe-in-charge *tor.
PR c++/69131
* method.c (walk_field_subobs): Add dtor_from_ctor parm.
(process_subob_fn): Likewise. Don't consider triviality if true.
(synthesize_method_walk): Pass it.
2016-01-19 Marek Polacek <polacek@redhat.com>
Backported from mainline
2016-01-19 Marek Polacek <polacek@redhat.com>
PR c++/68965
* pt.c (tsubst_copy): Mark elements in expanded vector as used.
2016-01-08 Marek Polacek <polacek@redhat.com>
PR c++/68449
* constexpr.c (cxx_eval_constant_expression): Handle NULL initializer.
2016-01-07 Jason Merrill <jason@redhat.com>
PR c++/68983
PR c++/67557
* call.c (unsafe_copy_elision_p): Look through COMPOUND_EXPR.
2015-12-22 Jason Merrill <jason@redhat.com>
PR c++/66921
* decl.c (cp_complete_array_type): Allow an initializer that
already has array type.
PR c++/67339
* parser.c (cp_parser_elaborated_type_specifier): Use CLASS_TYPE_P
rather than check for RECORD_TYPE.
2015-12-20 Jason Merrill <jason@redhat.com>
PR c++/67411
* decl2.c (decl_maybe_constant_var_p): Use DECL_HAS_VALUE_EXPR_P.
PR c++/67411
* decl2.c (decl_maybe_constant_var_p): A proxy isn't constant.
2015-12-17 Jason Merrill <jason@redhat.com>
PR c++/67550
* init.c (constant_value_1): Don't return a CONSTRUCTOR missing
non-constant elements.
PR c++/67576
PR c++/25466
* rtti.c (build_typeid): Use save_expr, not stabilize_reference.
2015-12-16 Joseph Myers <joseph@codesourcery.com>
PR c/68162
* tree.c (c_build_qualified_type): Add extra arguments.
2015-12-16 Jason Merrill <jason@redhat.com>
PR c++/63628
* pt.c (tsubst_pack_expansion): Also make dummy decls if
retrieve_local_specialization fails.
2015-12-04 Markus Trippelsdorf <markus@trippelsdorf.de>
PR c++/67337
* mangle.c (write_template_prefix): Guard against context==NULL.
2015-12-04 Release Manager
* GCC 5.3.0 released.
2015-11-26 Jakub Jelinek <jakub@redhat.com>
PR c++/68508
* cp-tree.h (cp_ubsan_maybe_instrument_downcast): Add INTYPE argument.
* cp-ubsan.c (cp_ubsan_maybe_instrument_downcast): Likewise. Use
it instead of or in addition to TREE_TYPE (op). Use
is_properly_derived_from, return NULL_TREE if TREE_TYPE (intype) and
TREE_TYPE (type) are the same type minus qualifiers.
* typeck.c (build_static_cast_1): Adjust callers.
2015-11-25 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2015-11-20 Jakub Jelinek <jakub@redhat.com>
PR c++/67354
* cp-tree.h (defer_mangling_aliases): Declare.
(generate_mangling_aliases): New prototype.
* decl2.c (defer_mangling_aliases): New variable.
(note_mangling_alias): Use !defer_mangling_aliases
instead of at_eof.
(generate_mangling_aliases): No longer static. Clear
defer_mangling_aliases.
* optimize.c (maybe_thunk_body): Defer emitting mangling aliases
if !defer_mangling_aliases until the fns are put into the same
comdat group.
2015-05-09 Aldy Hernandez <aldyh@redhat.com>
PR bootstrap/66085
* decl2.c (note_mangling_alias): Declare arguments as unused.
2015-05-08 Jason Merrill <jason@redhat.com>
* decl2.c (mangling_aliases): New variable.
(note_mangling_alias, generate_mangling_aliases): New.
(cp_write_global_declarations): Call generate_mangling_aliases.
(generate_mangling_alias): Split out from...
* mangle.c (mangle_decl): ...here.
* cp-tree.h: Declare note_mangling_alias.
2015-11-25 Jason Merrill <jason@redhat.com>
PR c++/67941
* lambda.c (maybe_add_lambda_conv_op): Mark _FUN as
no_sanitize_undefined.
PR c++/68422
* cp-tree.h (PACK_EXPANSION_SIZEOF_P): New.
* parser.c (cp_parser_sizeof_pack): Set it.
* pt.c (tsubst_copy) [SIZEOF_EXPR]: Likewise.
(tsubst_pack_expansion): Improve T... shortcut when set.
PR c++/67813
* constexpr.c (cxx_eval_store_expression): Always use *valp if
set.
2015-11-25 Markus Trippelsdorf <markus@trippelsdorf.de>
Paolo Carlini <paolo.carlini@oracle.com>
PR c++/68087
* constexpr.c (cxx_eval_array_reference): Use tree_fits_shwi_p before
tree_to_shwi to avoid ICEs.
2015-11-19 Jakub Jelinek <jakub@redhat.com>
Manuel López-Ibáñez <manu@gcc.gnu.org>
PR c++/67409
* decl.c (identify_goto): Add LOC and DIAG_KIND arguments, call
emit_diagnostic instead of permerror.
(check_previous_goto_1): Adjust identify_goto callers, treat all
cases but crossing initialization and entering scope of decl with
non-trivial dtor as unconditional hard errors.
(check_goto): Use identify_goto. Treat all cases but crossing
initialization and entering scope of decl with non-trivial dtor
as unconditional hard errors.
2015-10-20 Jason Merrill <jason@redhat.com>
PR c++/66583
* init.c (innermost_aggr_scope): New.
(sort_mem_initializers): Use it.
PR c++/67557
* call.c (is_base_field_ref): New.
(unsafe_copy_elision_p): New.
(build_over_call): Use it.
2015-09-12 Paolo Carlini <paolo.carlini@oracle.com>
Backport from mainline
2015-06-15 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/51048
* decl2.c (no_linkage_error): Do not issue a permerror if the DECL
using a local type is pure virtual.
2015-09-10 Jakub Jelinek <jakub@redhat.com>
PR c++/67522
* semantics.c (handle_omp_array_sections_1): Only run
type_dependent_expression_p on VAR_DECL/PARM_DECLs.
(finish_omp_clauses) <case OMP_CLAUSE_LINEAR>: Likewise.
Don't adjust OMP_CLAUSE_LINEAR_STEP if OMP_CLAUSE_DECL
is not a VAR_DECL/PARM_DECL.
PR c++/67511
* semantics.c (handle_omp_for_class_iterator): Don't wrap
error_mark_node into a NOP_EXPR to void_type_node.
2015-09-09 Jakub Jelinek <jakub@redhat.com>
PR c++/67504
* parser.c (cp_parser_omp_clause_collapse): Test tree_fits_shwi_p
before INTEGRAL_TYPE_P test.
2015-09-08 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/67369
* pt.c (tsubst_copy, [case FUNCTION_DECL]): Do not call tsubst
if the first argument isn't a template.
2015-08-17 Jason Merrill <jason@redhat.com>
PR c++/66957
* search.c (protected_accessible_p): Revert fix for 38579.
2015-08-17 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/66919
* pt.c (tsubst_copy): Pass complain to mark_used, check return value.
2015-08-17 Jason Merrill <jason@redhat.com>
PR c++/67244
* pt.c (tsubst_copy_and_build): Call insert_pending_capture_proxies.
PR c++/65734
* class.c (fixup_attribute_variants): Respect TYPE_USER_ALIGN.
PR c++/67104
* constexpr.c (cxx_eval_array_reference): Handle sparse
CONSTRUCTORs.
2015-08-14 Jason Merrill <jason@redhat.com>
PR c++/65974
* decl2.c (mark_vtable_entries): Suppress -Wdeprecated.
2015-08-14 Patrick Palka <ppalka@gcc.gnu.org>
PR c++/66857
* cvt.c (ocp_convert): Don't call scalar_constant_value when
converting to a class type.
2015-08-12 Jason Merrill <jason@redhat.com>
PR c++/67161
* error.c (dump_decl) [TEMPLATE_ID_EXPR]: Pass
TFF_NO_OMIT_DEFAULT_TEMPLATE_ARGUMENTS.
2015-08-06 Jason Merrill <jason@redhat.com>
PR c++/66533
* parser.c (cp_parser_primary_expression): Don't skip to the end
of the statement if we're parsing tentatively.
PR c++/67130
PR c++/67131
PR c++/66260
* mangle.c (write_expression) [TEMPLATE_ID_EXPR]: Handle variable
templates.
* pt.c (tsubst_copy_and_build): Check for argument substitution
failure.
2015-08-05 Jason Merrill <jason@redhat.com>
PR c++/66260
PR c++/66596
PR c++/66649
PR c++/66923
* pt.c (lookup_template_variable): Use NULL_TREE for type.
(instantiate_template_1): Also set DECL_TI_ARGS based on
the immediate parent.
(tsubst_copy_and_build) [TEMPLATE_ID_EXPR]: Handle variable templates.
(finish_template_variable): Add complain parm.
* cp-tree.h: Adjust.
PR c++/65195
PR c++/66619
* semantics.c (finish_id_expression): Call convert_from_reference
for variable template.
PR c++/66336
* pt.c (find_parameter_packs_r): Handle variable templates.
(variable_template_specialization_p): New.
* cp-tree.h: Declare it.
2015-07-30 Jason Merrill <jason@redhat.com>
DR 1558
PR c++/67021
* pt.c (tsubst_decl) [TYPE_DECL]: Clear TYPE_DEPENDENT_P_VALID.
2015-07-16 Marek Polacek <polacek@redhat.com>
Backported from mainline
2015-07-08 Marek Polacek <polacek@redhat.com>
PR c++/66748
* tree.c (handle_abi_tag_attribute): Check for CLASS_TYPE_P before
accessing TYPE_LANG_SPECIFIC node.
2015-07-16 Release Manager
* GCC 5.2.0 released.
2015-07-10 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2015-07-08 Jakub Jelinek <jakub@redhat.com>
* decl.c (grokfndecl): Handle flag_openmp_simd like flag_openmp.
* pt.c (apply_late_template_attributes): Likewise.
2015-07-02 Jason Merrill <jason@redhat.com>
PR c++/66743
* pt.c (for_each_template_parm_r) [UNDERLYING_TYPE]: Use
TYPE_VALUES_RAW rather than TYPE_FIELDS.
2015-06-30 Jason Merrill <jason@redhat.com>
PR c++/65945
* decl.c (cxx_init_decl_processing): Set TYPE_ALIGN of nullptr_t.
* class.c (layout_nonempty_base_or_field): Warn if that affects
the offset of a field.
2015-06-29 Adam Butcher <adam@jessamine.co.uk>
PR c++/65750
* parser.c (cp_parser_simple_type_specifier): Don't synthesize
implicit template parm if 'auto' is a placeholder for trailing
return type.
2015-06-26 Jason Merrill <jason@redhat.com>
PR c++/66216
* class.c (finish_struct): Call fixup_attribute_variants.
PR c++/66067
* mangle.c (write_template_args): Handle 0 length TREE_VEC.
2015-06-24 Jason Merrill <jason@redhat.com>
PR c++/65919
* mangle.c (mangle_decl): Always SET_IDENTIFIER_GLOBAL_VALUE.
(decl_implicit_alias_p): Split out from maybe_remove_implicit_alias.
* cp-tree.h (DECL_REALLY_EXTERN): Handle null DECL_LANG_SPECIFIC.
PR c++/66647
* pt.c (dependent_type_p_r): Check for dependent alias template
specialization sooner.
PR c++/66501
* init.c (vec_copy_assign_is_trivial): New.
(build_vec_init): Use it.
2015-06-24 Mikhail Maltsev <maltsevm@gmail.com>
Backport from mainline:
2015-06-20 Mikhail Maltsev <maltsevm@gmail.com>
PR c++/65882
* call.c (build_new_op_1): Check tf_warning flag in all cases.
2015-06-23 Jason Merrill <jason@redhat.com>
PR c++/65879
* tree.c (no_linkage_check): Skip the 'this' pointer.
2015-06-19 Jason Merrill <jason@redhat.com>
PR c++/66515
* call.c (implicit_conversion): Call reshape_init here, early.
(build_aggr_conv): Not here.
PR c++/66585
* pt.c (instantiate_class_template_1): Clear
cp_unevaluated_operand and c_inhibit_evaluation_warnings.
PR c++/65880
* decl.c (build_ptrmemfunc_type): Check TYPE_GET_PTRMEMFUNC_TYPE after
cv-qualifiers.
PR c++/65973
* constexpr.c (build_constexpr_constructor_member_initializers):
Handle an empty STATEMENT_LIST.
PR c++/65843
* pt.c (tsubst_copy_and_build): Register a capture proxy in
local_specializations.
2015-06-17 Jason Merrill <jason@redhat.com>
PR c++/66001
* constexpr.c (cxx_eval_constant_expression): Handle TRY_BLOCK and
TRY_FINALLY_EXPR.
(potential_constant_expression_1): Likewise.
2015-06-17 Jakub Jelinek <jakub@redhat.com>
PR c++/66571
* pt.c (tsubst_omp_clause_decl): New function.
(tsubst_omp_clauses): Use it or tsubst_copy instead of
tsubst_expr on OMP_CLAUSE_DECL.
2015-06-17 Jason Merrill <jason@redhat.com>
PR c++/66536
* tree.c (replace_placeholders_r) [CONSTRUCTOR]: Handle type
mismatch.
PR c++/58063
* tree.c (bot_manip): Remap SAVE_EXPR.
PR c++/66387
* pt.c (tsubst_copy) [VAR_DECL]: Use process_outer_var_ref.
PR c++/66450
* constexpr.c (cxx_eval_store_expression): Avoid messing up outer
ctx->ctor.
PR c++/66289
* cp-tree.h (TEMPLATE_DECL_COMPLEX_ALIAS_P): New.
* pt.c (push_template_decl_real): Set it.
(dependent_alias_template_spec_p): Use it.
(dependent_type_p_r): Use dependent_alias_template_spec_p.
(uses_all_template_parms_data, uses_all_template_parms_r)
(complex_alias_template_p): New.
(get_template_parm_index): Handle BOUND_TEMPLATE_TEMPLATE_PARM.
2015-06-12 Jason Merrill <jason@redhat.com>
PR c++/65719
* pt.c (tsubst_decl) [VAR_DECL]: Mark namespace-scope
variables as DECL_NOT_REALLY_EXTERN.
2015-06-11 Jason Merrill <jason@redhat.com>
PR c++/66445
* constexpr.c (potential_constant_expression_1): Handle a
DECL_EXPR of TYPE_DECL.
2015-06-11 Pierre-Marie de Rodat <derodat@adacore.com>
* decl.c (cxx_init_decl_processing): Register the main
translation unit through the new debug hook.
2015-06-09 Jason Merrill <jason@redhat.com>
PR c++/66387
* semantics.c (process_outer_var_ref): Make sure the value is
actually constant before returning it.
* typeck.c (cp_build_array_ref): Allow subscripting non-lvalue
array.
PR c++/66383
* tree.c (replace_placeholders_r): Handle placeholders for an
outer object.
* typeck2.c (store_init_value): Only replace_placeholders for
objects of class type.
2015-06-05 Jason Merrill <jason@redhat.com>
PR c++/66405
* pt.c (argument_pack_element_is_expansion_p): Return 2 if
the expansion has extra args.
(use_pack_expansion_extra_args_p): Return true in that case.
PR c++/66405
* pt.c (type_dependent_expression_p): EXPR_PACK_EXPANSION is
dependent even if it has a type.
2015-06-05 Jason Merrill <jason@redhat.com>
PR c++/65942
* decl2.c (mark_used): Don't always instantiate constexpr fns.
* constexpr.c (cxx_eval_call_expression): Instantiate them here.
2015-06-04 Marek Polacek <polacek@redhat.com>
Backported from mainline
2015-06-03 Marek Polacek <polacek@redhat.com>
PR sanitizer/66190
* cp-gimplify.c (struct cp_genericize_data): Add no_sanitize_p.
(cp_genericize_r): Don't instrument static initializers.
(cp_genericize_tree): Initialize wtd.no_sanitize_p.
2015-05-31 Jason Merrill <jason@redhat.com>
PR c++/66320
* constexpr.c (cxx_eval_constant_expression): Treat a placeholder
with the wrong type as non-constant.
* pt.c (tsubst_decl) [VAR_DECL]: SET_DECL_IMPLICIT_INSTANTIATION
before register_specialization.
2015-05-22 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2015-05-19 Jakub Jelinek <jakub@redhat.com>
PR middle-end/66199
* parser.c (cp_parser_omp_for_loop): Don't add
OMP_CLAUSE_SHARED to OMP_PARALLEL_CLAUSES when moving
OMP_CLAUSE_LASTPRIVATE clause to OMP_FOR_CLAUSES.
(cp_parser_omp_teams): Set OMP_TEAMS_COMBINED for combined
constructs.
2015-05-18 Jason Merrill <jason@redhat.com>
* pt.c (tsubst_decl) [VAR_DECL]: Call coerce_innermost_template_parms.
(determine_specialization): Call coerce_template_parms.
* tree.c (strip_typedefs_expr) [TRAIT_EXPR]: Fix typo.
(strip_typedefs) [DECLTYPE_TYPE]: Fix typedef of decltype.
[TREE_LIST]: Fix no-change case.
2015-05-07 Jason Merrill <jason@redhat.com>
PR c++/59012
* parser.c (cp_parser_std_attribute_list): Handle attribute expansion.
(cp_parser_std_attribute_spec): Handle alignas pack expansion.
* decl2.c (is_late_template_attribute): An attribute exp is dependent.
* pt.c (make_pack_expansion): Allow TREE_LIST for attribute expansion.
(apply_late_template_attributes): Handle attribute pack expansion.
DR 1467
PR c++/51747
* typeck2.c (digest_init_r): Fix single element list.
2015-05-05 Jason Merrill <jason@redhat.com>
* decl.c (start_decl): Don't push the plain VAR_DECL for a
variable template.
2015-05-04 Paolo Carlini <paolo.carlini@oracle.com>
Jakub Jelinek <jakub@redhat.com>
PR c++/66007
* typeck2.c (check_narrowing): Check by-hand that the pedwarn didn't
result in an actual error.
2015-05-01 Paolo Carlini <paolo.carlini@oracle.com>
Prathamesh Kulharni <prathamesh.kulkarni@linaro.org>
PR c++/65858
* typeck2.c (check_narrowing): Set ok = true when pedwarn returns
false.
2015-04-30 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/65801
* typeck2.c (check_narrowing): In C++11 mode too, -Wno-narrowing
suppresses the diagnostic.
2015-04-30 Jason Merrill <jason@redhat.com>
PR c++/65876
* constexpr.c (cxx_eval_call_expression): Fail gracefully if cgraph
threw away DECL_SAVED_TREE.
2015-04-29 Thomas Schwinge <thomas@codesourcery.com>
Backport from trunk r222564:
2015-04-29 Thomas Schwinge <thomas@codesourcery.com>
* pt.c (tsubst_expr) <OMP_TARGET_UPDATE>: Use
OMP_TARGET_UPDATE_CLAUSES instead of OMP_CLAUSES.
2015-04-28 Jason Merrill <jason@redhat.com>
PR c++/65896
* constexpr.c (cxx_eval_store_expression): Don't try to actually
store an empty class.
2015-04-22 Marek Polacek <polacek@redhat.com>
PR c++/65727
* lambda.c (maybe_resolve_dummy): Handle null return.
2015-04-22 Jason Merrill <jason@redhat.com>
PR c++/65695
* cvt.c (cp_fold_convert): Avoid wrapping PTRMEM_CST in NOP_EXPR.
PR c++/65721
* name-lookup.c (do_class_using_decl): Complain about specifying
the current class even if there are dependent bases.
2015-04-22 David Krauss <david_work@me.com>
PR c++/59766
* decl.c (grokdeclarator): Do not flag friends with deduced return.
2015-04-22 Release Manager
* GCC 5.1.0 released.
2015-04-20 Ilya Verbin <ilya.verbin@intel.com>
* parser.c (cp_parser_omp_target_update): Add missed %> to error_at ().
2015-04-12 Jakub Jelinek <jakub@redhat.com>
PR c++/65736
* constexpr.c (cxx_eval_pointer_plus_expression): Don't fold for VLAs,
don't fold if op01 isn't divisible by TYPE_SIZE_UNIT. Convert
the expression to the original type at the end.
2015-04-09 Jakub Jelinek <jakub@redhat.com>
PR c++/65690
* tree.c (cp_build_qualified_type_real): Copy TYPE_ALIGN and
TYPE_USER_ALIGN.
PR c++/65690
* tree.c (build_cplus_array_type): Layout type before variants are
set, but copy over TYPE_SIZE and TYPE_SIZE_UNIT from the main
variant.
2015-04-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/64085
* lambda.c (add_capture): Use dependent_type_p for capture by
reference too.
2015-04-02 Marek Polacek <polacek@redhat.com>
PR c++/65642
* constexpr.c (cxx_eval_pointer_plus_expression): Call
cxx_eval_constant_expression on the first operand.
2015-04-01 Jason Merrill <jason@redhat.com>
PR c++/65625
* decl.c (make_typename_type): Handle seeing a variable template.
2015-04-01 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/56100
* pt.c (instantiating_current_function_p): New.
* name-lookup.c (pushdecl_maybe_friend_1): Use it.
* cp-tree.h (instantiating_current_function_p): Declare.
2015-04-01 Jason Merrill <jason@redhat.com>
PR c++/65646
* decl.c (grokvardecl): Don't call check_explicit_specialization
for non-template members of a class template.
2015-04-01 Marek Polacek <polacek@redhat.com>
PR c++/65554
* class.c (finish_struct): Require that the second field of a
user-defined initializer_list be of size type.
2015-03-31 Marek Polacek <polacek@redhat.com>
PR c++/65390
* tree.c (build_cplus_array_type): Use dependent_type_p rather than
checking for constness.
2015-03-30 Marek Polacek <polacek@redhat.com>
PR c++/65398
* constexpr.c (cxx_fold_indirect_ref): Don't perform the
*(&A[i] p+ j) => A[i + j] transformation here.
(cxx_eval_pointer_plus_expression): New function.
(cxx_eval_constant_expression): Use it here.
2015-03-27 Tobias Burnus <burnus@net-b.de>
PR c/65586
* parser.c (cp_parser_omp_for, cp_parser_omp_parallel,
cp_parser_omp_distribute, cp_parser_omp_teams, cp_parser_omp_target,
cp_parser_omp_declare): Don't show error for skipped omp pragmas with
-fopenmp-simd.
2015-03-27 Marek Polacek <polacek@redhat.com>
PR c++/65556
* semantics.c (finish_switch_cond): If the unlowered type is not an
enum, use the type of the condition.
2015-03-27 Jason Merrill <jason@redhat.com>
PR c++/65509
* decl.c (make_rtl_for_nonlocal_decl): Don't defer static
constants.
2015-03-26 Mikhail Maltsev <maltsevm@gmail.com>
PR c++/65154
* init.c (build_vec_init): Fix initializing aggregates
with empty init list.
2015-03-26 Jason Merrill <jason@redhat.com>
PR c++/65525
* constexpr.c (potential_constant_expression_1): Handle MEM_REF.
2015-03-25 Marek Polacek <polacek@redhat.com>
PR c++/65558
* name-lookup.c (handle_namespace_attrs): Ignore abi_tag attribute
on an anonymous namespace.
2015-03-25 Marek Polacek <polacek@redhat.com>
PR c++/61670
* class.c (remove_zero_width_bit_fields): Check for null DECL_SIZE.
2015-03-24 Jason Merrill <jason@redhat.com>
PR c++/65046
* cp-tree.h (NAMESPACE_IS_INLINE): Remove.
* parser.c (cp_parser_namespace_definition): Don't set it.
* name-lookup.c (handle_namespace_attrs): Check
DECL_NAMESPACE_ASSOCIATIONS instead.
PR c++/65498
* pt.c (get_mostly_instantiated_function_type): Just return the
type of the partially instantiated template in DECL_TI_TEMPLATE.
2015-03-20 Marek Polacek <polacek@redhat.com>
PR c++/65398
* constexpr.c (cxx_fold_indirect_ref): Transform *(&A[i] p+ j) into
A[i + j].
2015-03-20 Marek Polacek <polacek@redhat.com>
PR c++/65072
* typeck.c (lookup_anon_field): Make sure we're dealing with the main
variant.
2015-03-19 Jason Merrill <jason@redhat.com>
PR c++/65046
Automatically propagate ABI tags to variables and functions
from their (return) type.
* class.c (check_tag): Handle variables and functions.
(mark_or_check_attr_tags): Split out from find_abi_tags_r.
(mark_or_check_tags): Likewise.
(mark_abi_tags): Use it. Rename from mark_type_abi_tags.
(check_abi_tags): Add single argument overload for decls.
Handle inheriting tags for decls.
* mangle.c (write_mangled_name): Call it.
(mangle_return_type_p): Split out from write_encoding.
(unmangled_name_p): Split out from write_mangled_name.
(write_mangled_name): Ignore abi_tag on namespace.
* cp-tree.h (NAMESPACE_IS_INLINE): Replace NAMESPACE_ABI_TAG.
* parser.c (cp_parser_namespace_definition): Set it.
* name-lookup.c (handle_namespace_attrs): Use arguments. Warn
about abi_tag attribute on non-inline namespace.
* tree.c (check_abi_tag_args): Split out from handle_abi_tag_attribute.
(handle_abi_tag_attribute): Allow tags on variables.
2015-03-19 Jakub Jelinek <jakub@redhat.com>
* decl2.c (cplus_decl_attributes): Also add "omp declare target"
attribute for DECL_EXTERNAL VAR_DECLs.
2015-03-18 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/65340
* call.c (build_over_call): Pass the tsubst_flags_t argument to
mark_used.
* decl2.c (mark_used): Inline the require_deduced_type call and
guard the error call.
2015-03-16 Jason Merrill <jason@redhat.com>
PR c++/65061
* parser.c (cp_parser_template_name): Call strip_using_decl.
2015-03-16 Marek Polacek <polacek@redhat.com>
DR 1688
PR c++/65327
* decl.c (grokdeclarator): Allow volatile and constexpr together.
2015-03-12 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/65323
* decl.c (check_default_argument): Don't call
maybe_warn_zero_as_null_pointer_constant.
2015-03-11 Aldy Hernandez <aldyh@redhat.com>
* cp-gimplify.c (simple_empty_class_p): New.
* cp-gimplify.c (cp_gimplify_expr): Handle RETURN_EXPR. Abstract
the code for empty class copies into simple_empty_class_p, and
adapt it to handle COMPOUND_EXPRs.
2015-03-10 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/65370
* decl.c (duplicate_decls): Call check_redeclaration_no_default_args
only if the location of newdecl doesn't match the location of olddecl.
2015-03-10 Jakub Jelinek <jakub@redhat.com>
PR c++/65127
* parser.c (parsing_nsdmi): Don't return true if current_class_ptr
is not a PARM_DECL.
2015-03-10 Jason Merrill <jason@redhat.com>
PR c++/65333
DR 1558
* pt.c (dependent_type_p_r): Check both class and alias template args.
2015-03-10 Jakub Jelinek <jakub@redhat.com>
PR c/65120
* parser.c (cp_parser_binary_expression): Check for tcc_comparison
before preparing arguments to warn_logical_not_parentheses.
Use maybe_constant_value on rhs.
2015-03-09 Jason Merrill <jason@redhat.com>
PR c++/65339
* call.c: Don't call maybe_resolve_dummy when calling a constructor.
2015-03-09 Jakub Jelinek <jakub@redhat.com>
PR c/65120
* parser.c (cp_parser_binary_expression): Don't warn for
!!x == y or !b == y where b is bool.
2015-03-06 Aldy Hernandez <aldyh@redhat.com>
* ptree.c (cxx_print_lambda_node): New.
(cxx_print_xnode): Handle LAMBDA_EXPR.
2015-03-03 Aldy Hernandez <aldyh@redhat.com>
PR c++/65295
* constexpr.c (cxx_eval_constant_expression): Remove assert in
RESULT_DECL handling.
2015-02-26 Marek Polacek <polacek@redhat.com>
PR c++/65202
* constexpr.c (cxx_eval_constant_expression): Don't evaluate
a RETURN_EXPR if its operand is null.
2015-02-25 Jason Merrill <jason@redhat.com>
PR c++/65209
* decl2.c (constrain_visibility) [VISIBILITY_ANON]: Clear
DECL_COMDAT.
(constrain_visibility_for_template): Handle reference arguments.
PR debug/58315
* decl.c (start_preparsed_function): Use create_artificial_label
for cdtor_label.
2015-02-17 Paolo Carlini <paolo.carlini@oracle.com>
Jakub Jelinek <jakub@redhat.com>
PR c++/65075
* constexpr.c (check_constexpr_bind_expr_vars): Allow
implicit typedefs for lambda types.
2015-02-13 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/60894
* decl.c (lookup_and_check_tag): Use strip_using_decl.
2015-02-13 Jason Merrill <jason@redhat.com>
PR c++/65054
* pt.c (template_args_equal): Look through conversions here.
* tree.c (cp_tree_equal): Not here.
2015-02-13 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/60211
* parser.c (cp_parser_pragma): Diagnose PRAGMA_IVDEP at
pragma_external context.
2015-02-13 Jason Merrill <jason@redhat.com>
PR c++/65051
* call.c (reference_binding): Don't look for bad conversion
if TO is incomplete.
2015-02-13 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/64970
* decl.c (make_typename_type): Pass tsubst_flags_t argument
to lookup_template_class.
2015-02-13 Jakub Jelinek <jakub@redhat.com>
PR ipa/65034
* decl.c (start_preparsed_function): Use void_type_node instead
of NULL_TREE as LABEL_DECL type.
2015-02-12 Jason Merrill <jason@redhat.com>
PR c++/64898
* mangle.c (write_mangled_name): Fix test for variable template
instantiation.
* decl.c (begin_destructor_body): Condition clobber on
-flifetime-dse.
2015-02-12 Andrea Azzarone <azzaronea@gmail.com>
PR c++/64959
* parser.c (lookup_literal_operator): Return all candidates.
(cp_parser_userdef_char_literal): Simplify error handling.
(cp_parser_userdef_numeric_literal): Pass tf_warning_or_error.
(cp_parser_userdef_string_literal): Pass tf_warning_or_error.
Also give higher priority to standard string UDL operator.
2015-02-12 Jakub Jelinek <jakub@redhat.com>
PR debug/55541
* cp-tree.h (BLOCK_OUTER_CURLY_BRACE_P): Define.
* decl.c (poplevel): If functionbody, try not to create an extra
BLOCK for function body and use subblocks as that, if it is non-NULL
and doesn't have siblings. Set BLOCK_OUTER_CURLY_BRACE_P flag.
(outer_curly_brace_block): Use BLOCK_OUTER_CURLY_BRACE_P flag.
PR sanitizer/64984
* except.c (check_noexcept_r): Return NULL for internal
calls.
2015-02-10 Jason Merrill <jason@redhat.com>
PR c++/64994
* constexpr.c (cxx_eval_call_expression): Walk the clone list.
2015-02-10 Jan Hubicka <hubicka@ucw.cz>
PR ipa/64982
* method.c (use_thunk): Do not check for stdarg thunks.
2015-02-06 Jason Merrill <jason@redhat.com>
PR c++/64899
* init.c (build_vec_init): Handle default-initialized array with
constexpr default constructor.
2015-02-04 Jakub Jelinek <jakub@redhat.com>
PR c/64824
PR c/64868
* parser.c (cp_parser_omp_atomic): Handle RDIV_EXPR.
2015-02-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/64877
* typeck.c (cp_build_binary_op): Avoid spurious -Waddress warnings
for generated expressions.
2015-02-02 Ville Voutilainen <ville.voutilainen@gmail.com>
PR c++/64901
* decl.c (duplicate_decls): Also duplicate DECL_FINAL_P and
DECL_OVERRIDE_P.
2015-02-02 Jason Merrill <jason@redhat.com>
* tree.c (handle_abi_tag_attribute): Diagnose invalid arguments.
2015-01-30 Joseph Myers <joseph@codesourcery.com>
* class.c, except.c, parser.c, pt.c: All callers of fatal_error
changed to pass input_location as first argument.
2015-01-29 Jakub Jelinek <jakub@redhat.com>
PR c++/64717
* cp-ubsan.c (cp_ubsan_instrument_vptr): Don't wrap vptr
into SAVE_EXPR.
2015-01-29 Jason Merrill <jason@redhat.com>
PR c++/49508
* semantics.c (finish_return_stmt): Suppress -Wreturn-type on
erroneous return statement.
PR c++/64521
* repo.c (repo_emit_p): It's OK for a clone to be extern at this
point.
2015-01-27 Caroline Tice <cmtice@google.com>
Committing VTV Cywin/Ming patch for Patrick Wollgast
* vtable-class-hierarchy.cc (vtv_generate_init_routine): Add
check for not TARGET_PECOFF at the VTV_PREINIT_PRIORITY checks.
2015-01-27 Jason Merrill <jason@redhat.com>
PR c++/58597
* lambda.c (maybe_add_lambda_conv_op): Check cfun rather than
current_function_decl.
PR c++/63889
* pt.c (finish_template_variable): Move from semantics.c.
Handle multiple template arg levels. Handle coercion here.
(lookup_template_variable): Not here.
2015-01-23 Jason Merrill <jason@redhat.com>
PR c++/64314
PR c++/57510
* typeck2.c (split_nonconstant_init_1): Remove a sub-CONSTRUCTOR
that has been completely split out.
PR c++/64701
* constexpr.c (cxx_eval_constant_expression): Don't crash on C++
statement codes.
PR c++/64727
* constexpr.c (cxx_eval_constant_expression): Allow for lvalue use
of CONST_DECL.
2015-01-21 Jason Merrill <jason@redhat.com>
PR c++/64603
* constexpr.c (cxx_eval_constant_expression): Only shortcut
constant CONSTRUCTORs.
PR c++/64647
* constexpr.c (ensure_literal_type_for_constexpr_object): Don't
give a hard error in a template instantiation.
2015-01-21 Richard Biener <rguenther@suse.de>
PR middle-end/64313
* decl.c (duplicate_decls): Call set_builtin_decl_declared_p
for builtins the user declared correctly.
2015-01-16 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/58614
* pt.c (unify): When BRACE_ENCLOSED_INITIALIZER_P (arg), handle
TREE_TYPE (elt) == error_mark_node.
2015-01-15 Jan Hubicka <hubicka@ucw.cz>
PR tree-optimization/62053
* tree.c (build_cplus_array_type): Layout type after variants are set.
2015-01-15 Jakub Jelinek <jakub@redhat.com>
* cp-gimplify.c (cp_genericize_r): Call
cp_ubsan_maybe_instrument_member_call for member calls.
(cp_ubsan_check_member_access_r): New function.
(cp_genericize_tree): Call cp_ubsan_instrument_member_accesses.
* cp-tree.h (cp_ubsan_maybe_instrument_member_call,
cp_ubsan_instrument_member_accesses,
cp_ubsan_maybe_instrument_downcast,
cp_ubsan_maybe_instrument_cast_to_vbase): New prototypes.
* cp-ubsan.c: New file.
* Make-lang.in (CXX_AND_OBJCXX_OBJS): Add cp/cp-ubsan.o.
* constexpr.c (cxx_eval_call_expression): Return void_node
for IFN_UBSAN_VPTR.
(potential_constant_expression_1): Return true for
UBSAN_NULL, UBSAN_BOUNDS and UBSAN_VPTR internal calls.
* typeck.c (build_class_member_access_expr): Provide locus
for COMPONENT_REFs.
(build_static_cast_1): Instrument downcasts.
* class.c (build_base_path): For -fsanitize=vptr and !fixed_type_p
add ubsan instrumentation for virtual_access.
* call.c: Include internal-fn.h.
(set_flags_from_callee): Handle internal calls.
2015-01-15 Momchil Velikov <momchil.velikov@gmail.com>
PR c++/59366
* name-lookup.c (pushdecl_maybe_friend_1): Hide friend functions
and function templates, declared only in the class.
* decl.c (duplicate_decls): Reveal hidden friend functions or
function templates, if they are redeclared outside the class.
2015-01-15 Jason Merrill <jason@redhat.com>
PR c++/64356
* constexpr.c (cxx_eval_binary_expression): Fix pasto.
PR c++/63283
* constexpr.c (potential_constant_expression_1): Handle reference
args in templates.
2015-01-15 Thomas Schwinge <thomas@codesourcery.com>
James Norris <jnorris@codesourcery.com>
Cesar Philippidis <cesar@codesourcery.com>
Ilmir Usmanov <i.usmanov@samsung.com>
Jakub Jelinek <jakub@redhat.com>
* parser.c: Include "gomp-constants.h".
(cp_parser_omp_clause_map): Use enum gomp_map_kind instead of enum
omp_clause_map_kind. Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
Use OMP_CLAUSE_SET_MAP_KIND.
(cp_parser_omp_construct, cp_parser_pragma): Handle
PRAGMA_OACC_CACHE, PRAGMA_OACC_DATA, PRAGMA_OACC_ENTER_DATA,
PRAGMA_OACC_EXIT_DATA, PRAGMA_OACC_KERNELS, PRAGMA_OACC_PARALLEL,
PRAGMA_OACC_LOOP, PRAGMA_OACC_UPDATE, PRAGMA_OACC_WAIT.
(cp_parser_omp_clause_name): Handle "async", "copy", "copyout",
"create", "delete", "deviceptr", "host", "num_gangs",
"num_workers", "present", "present_or_copy", "pcopy",
"present_or_copyin", "pcopyin", "present_or_copyout", "pcopyout",
"present_or_create", "pcreate", "vector_length", "wait".
(OACC_DATA_CLAUSE_MASK, OACC_ENTER_DATA_CLAUSE_MASK)
(OACC_EXIT_DATA_CLAUSE_MASK, OACC_KERNELS_CLAUSE_MASK)
(OACC_LOOP_CLAUSE_MASK, OACC_PARALLEL_CLAUSE_MASK)
(OACC_UPDATE_CLAUSE_MASK, OACC_WAIT_CLAUSE_MASK): New macros.
(cp_parser_omp_var_list_no_open): Handle OMP_CLAUSE__CACHE_.
(cp_parser_oacc_data_clause, cp_parser_oacc_data_clause_deviceptr)
(cp_parser_oacc_clause_vector_length, cp_parser_oacc_wait_list)
(cp_parser_oacc_clause_wait, cp_parser_omp_clause_num_gangs)
(cp_parser_omp_clause_num_workers, cp_parser_oacc_clause_async)
(cp_parser_oacc_all_clauses, cp_parser_oacc_cache)
(cp_parser_oacc_data, cp_parser_oacc_enter_exit_data)
(cp_parser_oacc_kernels, cp_parser_oacc_loop)
(cp_parser_oacc_parallel, cp_parser_oacc_update)
(cp_parser_oacc_wait): New functions.
* cp-tree.h (finish_oacc_data, finish_oacc_kernels)
(finish_oacc_parallel): New prototypes.
* semantics.c: Include "gomp-constants.h".
(handle_omp_array_sections): Handle GOMP_MAP_FORCE_DEVICEPTR. Use
GOMP_MAP_* instead of OMP_CLAUSE_MAP_*. Use
OMP_CLAUSE_SET_MAP_KIND.
(finish_omp_clauses): Handle OMP_CLAUSE_ASYNC,
OMP_CLAUSE_VECTOR_LENGTH, OMP_CLAUSE_WAIT, OMP_CLAUSE__CACHE_.
Use GOMP_MAP_* instead of OMP_CLAUSE_MAP_*.
(finish_oacc_data, finish_oacc_kernels, finish_oacc_parallel): New
functions.
2015-01-14 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/58671
* decl2.c (var_defined_without_dynamic_init): Handle gracefully
self-initialization.
2015-01-13 Jason Merrill <jason@redhat.com>
PR c++/64356
PR libstdc++/58777
* constexpr.c (cxx_eval_binary_expression): Don't VERIFY_CONSTANT
pointer expressions.
(cxx_eval_increment_expression): Likewise.
PR c++/64514
* pt.c (coerce_template_parameter_pack): Return NULL for a
zero-length fixed parameter pack with a pack expansion arg.
PR c++/64520
* pt.c (unify): Don't try to deduce to std::initializer_list<T...>.
2015-01-12 Jason Merrill <jason@redhat.com>
PR c++/64547
* constexpr.c (cxx_eval_call_expression): A call to a void
function doesn't need to return a value.
2015-01-09 Michael Collison <michael.collison@linaro.org>
* call.c: Include hash-set.h, machmode.h, vec.h, double-int.h,
input.h, alias.h, symtab.h, options.h, fold-const.h,
wide-int.h, and inchash.h due to flattening of tree.h.
* class.c: Ditto.
* constexpr.c: Ditto.
* cp-array-notation.c: Ditto.
* cp-gimplify.c: Ditto.
* cp-lang.c: Ditto.
* cp-objcp-common.c: Ditto.
* cvt.c: Ditto.
* decl2.c: Ditto.
* decl.c: Ditto.
* dump.c: Ditto.
* error.c: Ditto.
* except.c: Ditto.
* expr.c: Ditto.
* friend.c: Ditto.
* init.c: Ditto.
* lambda.c: Ditto.
* lex.c: Ditto.
* mangle.c: Ditto.
* name-lookup.c: Ditto.
* optimize.c: Ditto.
* parser.c: Ditto.
* pt.c: Ditto.
* ptree.c: Ditto.
* repo.c: Ditto.
* rtti.c: Ditto.
* search.c: Ditto.
* semantics.c: Ditto.
* tree.c: Ditto.
* typeck2.c: Ditto.
* typeck.c: Ditto.
2015-01-08 Jason Merrill <jason@redhat.com>
* cp-gimplify.c (cp_genericize): Use do_ubsan_in_current_function.
* decl.c (compute_array_index_type): Likewise.
* init.c (build_vec_init): Likewise.
* typeck.c (cp_build_binary_op): Likewise.
2015-01-08 Jason Merrill <jason@redhat.com>
* init.c (build_vec_init): Call ubsan_instrument_bounds to check
whether an initializer-list is too big for a VLA.
(throw_bad_array_length): Remove.
* cp-tree.h: Remove prototype.
2015-01-08 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/60753
* decl.c (grokfndecl): Add bool parameter.
(grokdeclarator): Adjust calls.
(start_decl): Don't set DECL_DELETED_FN here.
2015-01-06 Jason Merrill <jason@redhat.com>
* parser.c (cp_parser_nested_name_specifier_opt): Diagnose invalid
template-ids.
PR c++/64455
* pt.c (type_dependent_expression_p): Handle variable templates.
* constexpr.c (potential_constant_expression_1): Use it.
PR c++/64487
* semantics.c (finish_offsetof): Handle templates here.
* parser.c (cp_parser_builtin_offsetof): Not here.
PR c++/64496
* semantics.c (process_outer_var_ref): Diagnose lambda in local
class NSDMI.
2015-01-06 Ville Voutilainen <ville.voutilainen@gmail.com>
PR c++/64489
* class.c (check_field_decls): Make copy assignment operators
complex only in c++98 mode.
2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
PR c++/31397
* class.c (check_for_override): Warn when a virtual function is an
override not marked override.
2015-01-05 Trevor Saunders <tsaunders@mozilla.com>
* class.c (warn_hidden): Use auto_vec<tree> instead of tree_list to
hold base_fndecls.
(get_basefndecls): Adjust.
2015-01-05 Jakub Jelinek <jakub@redhat.com>
Update copyright years.
2015-01-05 Marek Polacek <polacek@redhat.com>
PR c/64423
* typeck.c (cp_build_array_ref): Pass loc down to
warn_array_subscript_with_type_char.
Copyright (C) 2015 Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.