OSDN Git Service

PR c++/35328
[pf3gnuchains/gcc-fork.git] / gcc / cp / ChangeLog
index 275ca4b..673bc6a 100644 (file)
@@ -1,3 +1,267 @@
+2008-03-10  Jakub Jelinek  <jakub@redhat.com>
+
+       PR c++/35328
+       * semantics.c (finish_omp_clauses): Look through NOP_EXPR even
+       if errorcount.
+
+       PR c++/35337
+       * semantics.c (finish_omp_clauses): Use %qD instead of %qE for
+       DECL_P in not a variable and appears more than once error messages.
+
+2008-03-07  Paolo Bonzini  <bonzini@gnu.org>
+
+       Revert:
+
+       2008-02-06  Douglas Gregor  <doug.gregor@gmail.com>
+
+       PR c++/35049
+       PR c++/35096
+       * typeck.c (structural_comptypes): Call cp_comptypes.
+       (comptypes): New; called from the C/C++ common bits to perform
+       strict checks.
+       (cp_comptypes): Renamed from comptypes, which is already used,
+       with a different signature, by the C++ front end.
+       (build_reinterpret_cast_1): Call cp_comptypes.
+       (ptr_reasonably_similar): Ditto.
+       * decl.c (decls_match): Ditto.
+       * cvt.c (convert_to_reference): Ditto.
+       * cp-tree.h (same_type_p): Ditto.
+       (same_or_base_type_p): Ditto.
+       (comptypes): Rename to cp_comptypes.
+       * pt.c (canonical_type_parameter): Call cp_comptypes.
+
+2008-03-07  Paolo Bonzini  <bonzini@gnu.org>
+
+       * cp-objcp-common.c (cxx_types_compatible_p): Remove obsolete
+       test for equivalence between pointer and references.
+
+2008-03-02  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
+
+       PR 24924
+       * class.c (finish_struct_anon): Use permerror instead of pedwarn.
+       (check_field_decls): Likewise.
+       (note_name_declared_in_class): Likewise.
+       * call.c (build_new_op): Likewise.
+       (convert_like_real): Likewise.
+       (build_over_call): Likewise.
+       * lex.c (unqualified_fn_lookup_error): Likewise.
+       * parser.c (cp_parser_template_id): Likewise.
+       * cvt.c (warn_ref_binding): Likewise.
+       (convert_to_reference): Likewise.
+       (ocp_convert): Likewise.
+       (convert_to_void): Use error instead of pedwarn.
+       * error.c (cp_cpp_error): Use pedantic_warning_kind.
+       * decl.c (compute_array_index_type): Use constant_expression_error.
+       
+2008-03-01  Douglas Gregor  <doug.gregor@gmail.com>
+
+       * parser.c (cp_lexer_next_token_is_decl_specifier_keyword): Note
+       that auto is either a storage class or a simple type specifier,
+       depending on the dialect.
+       (cp_parser_decl_specifier_seq): Complain about `auto' as a storage
+       specifier in C++98 mode, error in C++0x mode (since we don't
+       support auto as a type specifier, yet).
+       (cp_parser_storage_class_specifier_opt): Don't treat `auto' as a
+       storage specifier in C++0x mode.
+       (cp_parser_simple_type_specifier): Parse `auto' as a
+       simple-type-specifier, but error because we don't support it yet.
+
+2008-02-29  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
+
+       * parser.c (cp_parser_nonclass_name): New.
+       (cp_parser_pseudo_destructor_name): Use it instead of
+       cp_parser_type_name.
+       (cp_parser_type_name): Move code to cp_parser_nonclass_name.
+
+2008-02-29  Tom Tromey  <tromey@redhat.com>
+
+       * parser.c (struct cp_token) <input_file_stack_index>: Remove.
+       (cp_lexer_get_preprocessor_token): Update.
+       (cp_lexer_set_source_position_from_token): Don't call
+       restore_input_file_stack.
+       * lex.c (cxx_init): Don't use push_srcloc or pop_srcloc.
+
+2008-02-28  Richard Guenther  <rguenther@suse.de>
+
+       Revert:
+       2008-02-26  Richard Guenther  <rguenther@suse.de>
+
+       * decl.c (duplicate_decls): Remove decl from global mapping
+       before ggc_freeing it.
+
+2008-02-27  Jakub Jelinek  <jakub@redhat.com>
+
+       PR c++/35368
+       * rtti.c: Include c-pragma.h.
+       (push_abi_namespace, pop_abi_namespace): New functions.
+       (build_dynamic_cast_1, tinfo_base_init, get_pseudo_ti_index,
+       create_tinfo_types, emit_support_tinfos): Use them.
+       * Make-lang.in (cp/rtti.o): Depend on $(C_PRAGMA_H).
+
+2008-02-26  Jason Merrill  <jason@redhat.com>
+
+       PR c++/35315
+       * decl.c (grokdeclarator): Allow a typedef of an unnamed struct
+       to name the struct for linkage purposes even if it has attributes.
+       (start_decl): In that case, set ATTR_FLAG_TYPE_IN_PLACE.
+
+2008-02-26  Tom Tromey  <tromey@redhat.com>
+
+       * parser.c (eof_token): Remove old location code.
+       (check_empty_body): Remove test of USE_MAPPED_LOCATION.
+       * decl2.c (generate_ctor_or_dtor_function): Remove old location
+       code.
+       (cp_write_global_declarations): Likewise.
+       * lex.c (cxx_init): Remove old location code.
+       (handle_pragma_implementation): Remove test of
+       USE_MAPPED_LOCATION.
+       * pt.c (tsubst): Remove old location code.
+       * error.c (cp_print_error_function): Remove test of
+       USE_MAPPED_LOCATION.
+       * decl.c (pop_label): Remove old location code.
+       (finish_function): Likewise.
+
+2008-02-26  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
+
+       PR 26264
+       * call.c (magic_varargs_p):  Remove BUILT_IN_STDARG_START.
+       
+2008-02-26  Richard Guenther  <rguenther@suse.de>
+
+       * decl.c (duplicate_decls): Remove decl from global mapping
+       before ggc_freeing it.
+
+2008-02-26  Paolo Carlini  <pcarlini@suse.de>
+
+        PR c++/35323
+        * name-lookup.c (arg_assoc_type): Handle FIXED_POINT_TYPE.
+
+2008-02-26  Manuel Lopez-Ibanez <manu@gcc.gnu.org>
+       
+       * typeck.c (build_class_member_access_expr): Add appropriate
+       OPT_W* parameter to warning.
+       (build_reinterpret_cast_1): Likewise.
+       * name-lookup.c (push_overloaded_decl): Likewise.
+       
+2008-02-25  Paolo Carlini  <pcarlini@suse.de>
+
+        PR c++/35333
+        * error.c (dump_expr): Handle CONJ_EXPR.
+
+2008-02-25  Paolo Carlini  <pcarlini@suse.de>
+
+        PR c++/35338
+        * error.c (dump_type): Handle FIXED_POINT_TYPE.
+       (dump_expr): Handle FIXED_CST.
+
+2008-02-24  Jason Merrill  <jason@redhat.com>
+
+       * parser.c (cp_parser_declaration): Handle "inline namespace".
+       (cp_parser_namespace_definition): Likewise.
+
+       PR c++/33486
+       * name-lookup.c (arg_assoc_namespace): Look down into inline 
+       namespaces, too.
+
+2008-02-23  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
+
+       * typeck.c (check_for_casting_away_constness): Use 1 single
+       argument, the type of cast, to decide what diagnostics generate.
+       (build_static_cast_1): Remove unused code. Update call to
+       check_for_casting_away_constness.
+       (build_reinterpret_cast_1): Update call to
+       check_for_casting_away_constness.
+       (build_const_cast_1): Likewise.
+       
+2008-02-24  Paolo Carlini  <pcarlini@suse.de>
+
+       * error.c (dump_expr): Don't deal directly with NEW_EXPR (and
+       VEC_NEW_EXPR), forward to pp_expression.
+       * cxx-pretty-print.c (pp_cxx_new_expression): Fix FIXME.
+
+2008-02-24  Danny Smith  <dannysmith@users.sourceforge.net>
+
+       PR c++/34749
+       * friend.c (do_friend): Call cplus_decl_attributes earlier.
+
+2008-02-22  Andrew Pinski  <andrew_pinski@playstation.sony.com>
+
+       PR C++/34715
+       * decl.c (duplicate_decls): Merge DECL_DISREGARD_INLINE_LIMITS for
+       template decls' function decl.
+
+2008-02-22  Paolo Carlini  <pcarlini@suse.de>
+
+       PR c++/35282
+       Revert:
+       2008-02-14  Paolo Carlini  <pcarlini@suse.de>
+
+        PR c++/28743
+        * pt.c (determine_specialization): In case of function templates,
+       when the type of DECL does not match FN there is no match.
+
+2008-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
+
+       PR c/19999
+       * typeck.c (build_binary_op): Warn about floating point
+       comparisons if FLOAT_TYPE_P, not only for REAL_TYPE.
+
+2008-02-19  Jason Merrill  <jason@redhat.com>
+
+       PR c++/34950
+       * pt.c (resolve_overloaded_unification): Set processing_template_decl
+       while we look for possible bindings.
+
+2008-02-19  Jakub Jelinek  <jakub@redhat.com>
+
+       PR c++/35028
+       * cp-gimplify.c (cxx_omp_clause_apply_fn): Handle vararg copy ctors.
+
+       PR c++/34964
+       PR c++/35244
+       * semantics.c (finish_omp_threadprivate): Do nothing for error_operand_p
+       vars.  Afterwards ensure v is VAR_DECL.
+
+       PR c++/35078
+       * parser.c (cp_parser_omp_for_loop): If DECL has REFERENCE_TYPE, don't
+       call cp_finish_decl.
+       * semantics.c (finish_omp_for): Fail if DECL doesn't have integral type
+       early.
+
+2008-02-15  Douglas Gregor  <doug.gregor@gmail.com>
+
+       PR c++/35023
+       PR c++/35024
+       PR c++/35026
+       * pt.c (finish_member_template_decl): If the type in a TYPE_DECL
+       is error_mark_node, return an error early.
+       (find_parameter_packs_r): Pass the pointer set along to recursive
+       calls of cp_walk_subtrees; don't try to manage the pointer set
+       ourselves.
+       (uses_parameter_packs): Pass the pointer set to cp_walk_tree.
+       (make_pack_expansion): Ditto.
+       (check_for_bare_parameter_packs): Ditto. Also, don't bother taking
+       a second pass through the tree with find_parameter_packs_r; that
+       second pass no longer does anything.
+       (push_template_decl_real): If we have an erroneous declaration,
+       set its type to error_mark_node before returning an error.
+
+2008-02-14  Douglas Gregor  <doug.gregor@gmail.com>
+
+       PR c++/34050
+       * pt.c (tsubst_initializer_list): Deal with the use of
+       VOID_TYPE_NODE to indicate value-initialization of the bases.
+
+2008-02-14  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
+           Jason Merrill  <jason@redhat.com>
+
+       PR c++/5645
+       PR c++/11159
+       * class.c (type_has_user_nondefault_constructor): New fn.
+       * cp-tree.h: Declare it.
+       * init.c (emit_mem_initializers): Use it for -W warning about
+       missing base initializer.
+
 2008-02-14  Paolo Carlini  <pcarlini@suse.de>
 
         PR c++/28743
 2008-02-12  Jason Merrill  <jason@redhat.com>
 
        PR c++/34824
-       * call.c (convert_like_real): Pass LOOKUP_ONLYCONVERTING to build_temp
+       * call.c (convert_like_real): Pass LOOKUP_NO_CONVERSION to build_temp
        if we're doing conversions to call a user-defined conversion function.
 
 2008-02-12  Steven Bosscher  <steven@gcc.gnu.org>