OSDN Git Service

Index: ChangeLog
[pf3gnuchains/gcc-fork.git] / gcc / cp / ChangeLog
index 0a21f0a..fe319c1 100644 (file)
@@ -1,3 +1,404 @@
+2005-06-13  Geoffrey Keating  <geoffk@apple.com>
+
+       * Make-lang.in (c++.install-man): Doesn't really depend on installdirs.
+       (rule for installing g++.1 manpage): Does depend on installdirs.
+
+2005-06-13  Nathan Sidwell  <nathan@codesourcery.com>
+
+       PR c++/20789
+       * decl.c (cp_finish_decl): Clear runtime runtime initialization if
+       in-class decl's initializer is bad.
+
+       PR c++/21929
+       * parser.c (struct cp_parser): Document that scope could be
+       error_mark.
+       (cp_parser_diagnose_invalid_type_name): Cope with error_mark for
+       scope.
+       (cp_parser_nested_name_specifier): Return NULL_TREE on error.
+       (cp_parser_postfix_expression): Deal with null or error_mark
+       scope.
+       (cp_parser_elaborated_type_specifier): Adjust
+       cp_parser_nested_name_specifier call.
+
+       * parser (cp_parser_skip_to_end_of_block_or_statement): Cleanup.
+
+2005-06-12  Roger Sayle  <roger@eyesopen.com>
+
+       PR c++/21930
+       * error.c (dump_expr): UNARY_PLUS_EXPR need not handle void types.
+       Treat CONVERT_EXPR identically to NOP_EXPR.
+
+2005-06-10  Aldy Hernandez  <aldyh@redhat.com>
+
+       PR c++/10611
+       * cvt.c (build_expr_type_conversion): Same.
+       * typeck.c (build_binary_op): Handle vectors.
+       (common_type): Same.
+       (type_after_usual_arithmetic_conversions): Same.
+       * testsuite/g++.dg/conversion/simd2.C: New.
+
+2005-06-08  Nathan Sidwell  <nathan@codesourcery.com>
+
+       PR c++/19497
+       * cp-tree.def (USING_DECL): Update documentation.
+       * cp-tree.h (DECL_DEPENDENT_P): New.
+       (USING_DECL_DECLS, USING_DECL_SCOPE): New.
+       * class.c (handle_using_decl): Move most of the processing to ...
+       * name-lookup.c (do_class_using_decl): ... here.  Make stricter.
+       (push_using_decl): Use USING_DECL_SCOPE.
+       (cp_emit_debug_info_for_using): Make extern.
+       * cxx-pretty-print.c (pp_cxx_statement) <USING_DECL case>: Adjust.
+       * name-lookup.h (cp_emit_debug_info_for_using): Declare.
+       * pt.c (tsubst_decl) <USING_DECL case>: Use do_class_using_decl
+       when tsubsting.
+       (tsubst_expr): Use USING_DECL_SCOPE.
+       * search.c (lookup_field_1): Use DECL_DEPENDENT_P.
+       * semantics.c (finish_member_declaration): Likewise.
+
+2005-06-08  Volker Reichelt  <reichelt@igpm.rwth-aachen.de>
+
+       PR c++/19894
+       * pt.c (tsubst): Reject pointer-to-member of type void.
+
+       PR c++/20563
+       * parser.c (cp_parser_label_declaration): Deal with invalid/missing
+       identifiers.
+
+2005-06-07  Nathan Sidwell  <nathan@codesourcery.com>
+
+       * cp-tree.def (DEFAULT_ARG): Adjust documentation.
+       * cp-tree.h (DEFARG_INSTANTIATIONS): New.
+       (struct tree_default_arg): Add instantiations member.
+       * parser.c (cp_parser_late_parsing_default_args): Adjust to use a
+       VEC.
+       * pt.c (tsubst_arg_types): Likewise.
+
+       * parser.c (cp_parser_late_parsing_default_args): Fix overeager
+       assert in previous patch.
+
+2005-06-06  Jakub Jelinek  <jakub@redhat.com>
+
+       * error.c (locate_error): Use gmsgid instead of msgid for argument
+       name.
+       (cp_error_at, cp_warning_at, cp_pedwarn_at): Likewise.
+
+2005-06-06  Nathan Sidwell  <nathan@codesourcery.com>
+
+       PR 21903
+       * cp-tree.def (DEFAULT_ARG): Document TREE_CHAIN use.
+       * parser.c (cp_parser_late_parsing_default_args): Propagate parsed
+       argument to any early instantiations.
+       * pt.c (tsubst_arg_types): Chain early instantiation of default arg.
+
+       PR c++/20637
+       * cp-tree.h (add_method): Add using_decl parameter.
+       * class.c (add_method): Add using_decl parameter.  Adjust error
+       messages.
+       (handle_using_decl): Pass the using decl to add_method.
+       (clone_function_decl): Adjust add_member calls.
+       * decl2.c (check_classfn): Likewise.
+       * method.c (lazily_declare_fn): Likewise.
+       * semantics.c (finish_member_declaration): Likewise.
+
+       * method.c (synthesize_method): Use inform, not warning.
+
+2005-06-06  Hans-Peter Nilsson  <hp@axis.se>
+
+       * config-lang.in (target_libs): Remove target-gperf.
+
+2005-06-05  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/21619
+       * cp-tree.h (DECL_IS_BUILTIN_CONSTANT_P): New macro.
+       * parser.c (cp_parser_postfix_expression): Allow non-constant
+       expressions as arguments to __builtin_constant_p.
+       * tree.c (builtin_valid_in_constant_expr_p): Use
+       DECL_IS_BUILTIN_CONSTANT_P. 
+
+2005-06-03  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/21853
+       * typeck.c (casts_away_constness_r): Do not drop cv-qualifiers on
+       the pointed-to type for a pointer-to-member.
+
+       PR c++/21336
+       * cp-tree.h (grok_op_properties): Remove friendp parameter.
+       * decl.c (grokfndecl): Adjust call.
+       (grok_op_properties): Determine the class of which the function is
+       a member by looking at its DECL_CONTEXT, not current_class_type.
+       * pt.c (tsubst_decl): Adjust call to grok_op_properties.
+
+2005-06-02  Nathan Sidwell  <nathan@codesourcery.com>
+
+       * method.c (synthesize_method): Add addtional arg to warning call.
+
+       PR c++/21280
+       * Make-lang.in (method.o): Add diagnostic.h
+       * decl.c (start_preparsed_function): Use decl's location for file
+       info.
+       * decl2.c (cp_finish_file): Set input_location before synthesizing
+       a function.
+       (mark_used): When deferring a synthesized function, save current
+       location.  Do not set function's location when actually
+       synthesizing it.
+       * method.c: #include diagnostic.h.
+       (synthesize_method): Set the functions source location.  Show
+       needed location if errors are emitted.
+
+       * decl.c (start_decl): Simplify specialization handling. Remove
+       unneeded CLASSTYPE_TEMPLATE_INSTANTIATION check.
+       * mangle.c (discriminator_for_local_entity): Use VEC_index.
+
+       PR c++/20350
+       * decl.c (duplicate_decls): Copy all of DECL_USE_TEMPLATE.
+
+       PR c++/21151
+       * name-lookup.c (pushtag): Push local class even in a template.
+
+2005-05-31  Nathan Sidwell  <nathan@codesourcery.com>
+
+       PR c++/21165
+       * init.c (integral_constant_value): Check the type of the
+       initializer, not the decl.
+
+2005-05-30  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/21784
+       * name-lookup.c (do_nonmember_using_decl): Ignore builtin
+       functions, even when the used name is not a function.
+
+2005-05-30  Kazu Hirata  <kazu@cs.umass.edu>
+
+       * operators.def, optimize.c: Update copyright.
+
+2005-05-28  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/21210
+       * call.c (standard_conversion): Permit conversions to complex
+       types if conversion to the corresponding scalar type would be
+       permitted.
+
+       PR c++/21340
+       * method.c (implicitly_declare_fn): Clear processing_template_decl
+       when generating implicit declaration.
+
+2005-05-27  Mark Mitchell  <mark@codesourcery.com>
+
+       PR c++/21614
+       * typeck.c (get_member_function_from_ptrfunc): Do not attempt
+       conversions to base classes of incomplete types.
+
+2005-05-27  Ian Lance Taylor  <ian@airs.com>
+
+       * semantics.c (add_stmt): Add C++ frontend specific version.
+       * cp-tree.h (STMT_IS_FULL_EXPR_P): Define.
+       (stmts_are_full_exprs_p): Declare.
+
+2005-05-27  Roger Sayle  <roger@eyesopen.com>
+           Giovanni Bajo  <giovannibajo@gcc.gnu.org>
+
+       * cp-tree.def (UNARY_PLUS_EXPR): New C++ unary tree code.
+       * parser.c (cp_parser_unary_expression): Use UNARY_PLUS_EXPR instead
+       of CONVERT_EXPR.
+       (cp_parser_unary_expression): Likewise.
+       * typeck.c (build_unary_op): Likewise.
+       * call.c (add_builtin_candidate, build_new_op): Likewise.
+       * error.c (dump_expr): Likewise.
+       * pt.c (tsubst_copy, tsubst_copy_and_build): Likewise.
+       * decl.c (ambi_op_p, grok_op_properties): Likewise.
+       * dump.c (dump_op): Likewise.
+       * lex.c (init_operators): Likewise.
+       * operators.def ("+"): Likewise.
+       * cp-gimplify.c (cp_gimplify_expr): Handle UNARY_PLUS_EXPR like a
+       conversion, if the result and argument types differ.
+       * tree.c (fold_if_not_in_template): Fold UNARY_PLUS_EXPR much
+       like a NOP_EXPR when !processing_template_decl.
+
+       * cxx-pretty-print.c (pp_cxx_cast_expression): Prototype.
+       (pp_cxx_unary_expression): Handle new UNARY_PLUS_EXPR tree code.
+
+2005-05-27  Nathan Sidwell  <nathan@codesourcery.com>
+
+       PR c++/21455
+       * typeck.c (get_delta_difference): Cope with incomplete but equal
+       classes.  Reorder if.
+
+       PR c++/21681
+       * parser.c (cp_parser_late_parsing_for_member): Disable access
+       checking for template functions.
+
+2005-05-26  Volker Reichelt  <reichelt@igpm.rwth-aachen.de>
+
+       PR c++/21768
+       * pt.c (redeclare_class_template): Change error message according
+       to coding conventions.
+
+2005-05-26  Volker Reichelt  <reichelt@igpm.rwth-aachen.de>
+
+       * call.c (build_op_delete_call): Fix quoting in error message.
+
+2005-05-25  Richard Henderson  <rth@redhat.com>
+
+       PR libgcj/21692
+       * cp-tree.h (make_alias_for): Declare.
+       * decl2.c (build_java_method_aliases): New.
+       (cp_finish_file): Call it.
+       * method.c (make_alias_for): Split out from ...
+       (make_alias_for_thunk): ... here.
+
+2005-05-25  Volker Reichelt  <reichelt@igpm.rwth-aachen.de>
+
+       PR c++/21686
+       * semantics.c (finish_id_expression): Fix quoting in error message.
+
+2005-05-25  DJ Delorie  <dj@redhat.com>
+
+       * decl.c (duplicate_decls): Move warning control from if() to
+       warning(OPT_*).
+       * name-lookup.c (parse_using_directive): Likewise.
+       * parser.c (cp_parser_elaborated_type_specifier): Likewise.
+       (cp_parser_init_declarator): Likewise.
+       * tree.c (handle_com_interface_attribute): Likewise.
+
+2005-05-24  Ziemowit Laski  <zlaski@apple.com>
+
+       * class.c (layout_class_type): Do not issue C++ ABI warnings
+       for ObjC structs.
+       * decl.c (objc_mark_locals_volatile): Streamline by calling
+       objc_volatilize_decl().
+       * parser.c (cp_parser_objc_message_expression): Allow simple
+       type specifiers (instead of merely type names) as message
+       receivers.
+       * pt.c (template_args_equal): Do not call objc_comptypes().
+       * typeck.c (composite_pointer_type): If both pointers are
+       ObjC-esque, arbitrarily choose the first; do not call
+       objc_comptypes().
+       (comptypes): Do not call objc_comptypes().
+       (convert_for_assignment): Call objc_compare_types().
+       (comp_ptr_ttypes_real): Call objc_type_quals_match() before
+       concluding that types do not match.
+
+2005-05-24  Andrew Pinski  <pinskia@physics.uc.edu>
+
+       PR C++/21645
+       * optimize.c (update_cloned_parm): Copy the TYPE also from the
+       original one.
+
+2005-05-19  Jakub Jelinek  <jakub@redhat.com>
+
+       PR c++/21495
+       * decl.c (grokdeclarator): Fix "storage class specified for"
+       error reporting.
+
+2005-05-19  Kazu Hirata  <kazu@cs.umass.edu>
+
+       * parser.c: Fix comment typos.
+
+2005-05-18  Geoffrey Keating  <geoffk@apple.com>
+
+       * Make-lang.in (cc1plus-dummy): New.
+       (cc1plus-checksum.c): New.
+       (cc1plus-checksum.o): New.
+       (cc1plus): Add cc1plus-checksum.o.
+
+2005-05-17  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR C++/19664
+       * decl2.c (determine_visibility): Don't set visibility to
+       hidden if it has been set explicitly by user.
+
+2005-05-17  Ziemowit Laski  <zlaski@apple.com>
+           Mike Stump  <mrs@apple.com>
+
+       Yet more Objective-C++...
+       
+       * cp-objcp-common.h (cxx_get_alias_set): Move from
+       here...
+       (cxx_warn_unused_global_decl): Likewise.
+       (cp_expr_size): Likewise.
+       (cp_tree_size): Likewise.
+       (cp_var_mod_type_p): Likewise.
+       (cxx_initialize_diagnostics): Likewise.
+       (cxx_types_compatible_p): Likewise.
+       * cp-tree.h: to here.
+       (do_poplevel): Add.
+       * lex.c (D_OBJC): Add.
+       (init_reswords): Add.
+       * Make-lang.in (cp/pt.o): Add cp/cp-objcp-common.h.
+       * parser.c: Add c-common.h include.
+       * pt.c: Add c-common.h and cp-objcp-common.h includes.
+       (template_args_equal): Use objc_comptypes as well.
+       (tsubst_copy_and_build): Use objcp_tsubst_copy_and_build as well.
+       * semantics.c (do_poplevel): Remove static.
+
+       * decl.c (objc_mark_locals_volatile): Don't change decls that are
+       already ok.
+       * decl2.c (generate_ctor_or_dtor_function): Add code to initialize
+       Objective C++ early enough.
+       * lex.c (struct resword reswords): Add Objective-C++ support.
+       * parser.c (cp_lexer_get_preprocessor_token): Add Objective-C++.
+       (cp_parser_objc_message_receiver): Add.
+       (cp_parser_objc_message_args): Likewise.
+       (cp_parser_objc_message_expression): Likewise.
+       (cp_parser_objc_encode_expression): Likewise.
+       (cp_parser_objc_defs_expression): Likewise.
+       (cp_parser_objc_protocol_expression): Likewise.
+       (cp_parser_objc_selector_expression): Likewise.
+       (cp_parser_objc_expression): Likewise.
+       (cp_parser_objc_visibility_spec): Likewise.
+       (cp_parser_objc_method_type): Likewise.
+       (cp_parser_objc_protocol_qualifiers): Likewise.
+       (cp_parser_objc_typename): Likewise.
+       (cp_parser_objc_selector_p): Likewise.
+       (cp_parser_objc_selector): Likewise.
+       (cp_parser_objc_method_keyword_params): Likewise.
+       (cp_parser_objc_method_tail_params_opt): Likewise.
+       (cp_parser_objc_interstitial_code): Likewise.
+       (cp_parser_objc_method_signature): Likewise.
+       (cp_parser_objc_method_prototype_list): Likewise.
+       (cp_parser_objc_method_definition_list): Likewise.
+       (cp_parser_objc_class_ivars): Likewise.
+       (cp_parser_objc_identifier_list): Likewise.
+       (cp_parser_objc_alias_declaration): Likewise.
+       (cp_parser_objc_class_declaration): Likewise.
+       (cp_parser_objc_protocol_declaration): Likewise.
+       (cp_parser_objc_protocol_refs_opt): Likewise.
+       (cp_parser_objc_superclass_or_category): Likewise.
+       (cp_parser_objc_class_interface): Likewise.
+       (cp_parser_objc_class_implementation): Likewise.
+       (cp_parser_objc_end_implementation): Likewise.
+       (cp_parser_objc_declaration): Likewise.
+       (cp_parser_objc_try_catch_finally_statement): Likewise.
+       (cp_parser_objc_synchronized_statement): Likewise.
+       (cp_parser_objc_throw_statement): Likewise.
+       (cp_parser_objc_statement): Likewise.
+       (cp_parser_primary_expression): Add Objective-C++.
+       (cp_parser_statement): Likewise.
+       (cp_parser_declaration): Likewise.
+       (cp_parser_simple_type_specifier): Likewise.
+       (cp_parser_type_name): Likewise.
+       (cp_parser_parameter_declaration_list): Likewise.
+       (cp_parser_member_declaration) Likewise.
+       * tree.c: Include debug.h.
+       * typeck.c (composite_pointer_type): Add Objective-C++ support.
+       (finish_class_member_access_expr): Likewise.
+       (build_function_call): Allow objc to rewrite FUNCTION_DECLs.
+       (build_modify_expr): Allow objc to generate write barriers.
+
+       * Make-lang.in (cp/tree.o): Add debug.h.
+       * tree.c (lvalue_p_1, case CONST_DECL): Add.
+
+2005-05-18  Jan Hubicka  <jh@suse.cz>
+
+       * method.c: Include tree-pass.h
+       (use_thunk): Lower body before expanding.
+
+2005-05-17  Jakub Jelinek  <jakub@redhat.com>
+
+       PR c++/21454
+       * decl.c (maybe_deduce_size_from_array_init): Call
+       cp_apply_type_quals_to_decl after completing array type.
+
 2005-05-16  Richard Henderson  <rth@redhat.com>
 
        * decl.c (build_library_fn_1): Move setting TREE_NOTHROW ...
 
 2005-05-02  Paolo Bonzini  <bonzini@gnu.org>
 
-        * semantics.c (finish_call_expr): Call resolve_overloaded_builtin
-        for BUILT_IN_MD built-ins.
+       * semantics.c (finish_call_expr): Call resolve_overloaded_builtin
+       for BUILT_IN_MD built-ins.
 
 2005-05-02  Michael Matz  <matz@suse.de>
 
 2005-04-22  Per Bothner  <per@bothner.com>
 
        * decl.c (make_rtl_for_nonlocal_decl): Don't try get_fileinfo if
-        input_filename is NULL, as it is for (say) __PRETTY_FUNCTION__.
+       input_filename is NULL, as it is for (say) __PRETTY_FUNCTION__.
 
 2005-04-22  Alexandre Oliva  <aoliva@redhat.com>