- 05 Jun, 2000 1 commit
-
-
mmitchel authored
* mangle.c (write_expression): Handle non-type template arguments with reference type. * method.c (build_overload_value): Likewise. * pt.c (convert_nontype_argument): Explicitly represent conversion to a reference with an ADDR_EXPR. (unify): Always unify arguments in left-to-right order. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34396 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 04 Jun, 2000 1 commit
-
-
mmitchel authored
* Makefile.in (CXX_OBJS): Add mangle.o. (mangle.o): New rule. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34394 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 03 Jun, 2000 1 commit
-
-
mmitchel authored
(INNERMOST_TEMPLATE_ARGS): New macro. (innermost_args): Remove. (get_innermost_template_args): New function. * decl2.c (arg_assoc_class): Use INNERMOST_TEMPLATE_ARGS. * error.c (dump_function_decl): Be caution when using most_general_template. * method.c (build_template_parm_names): Use INNERMOST_TEMPLATE_ARGS. * pt.c (add_to_template_args): Tidy comment (get_innermost_template_args): New function. (check_explicit_specialization): Clear DECL_INITIAL for a new specialization. (process_partial_specialization): Use INNERMOST_TEMPLATE_ARGS. Tidy. (push_template_decl): Always register specializations of the most general template. (convert_template_argument): Use INNERMOST_TEMPLATE_ARGS. (coerce_template_parms): Likewise. (lookup_template_class): Likewise. (innermost_args): Remove. (tsubst_decl): Use INNERMOST_TEMPLATE_ARGS. (tsubst_decl): Handle tricky specializations. Use get_innermost_template_args. (instantiate_template): Simplify handling of partial instantiations. (get_class_bindings): Use INNERMOST_TEMPLATE_ARGS. (most_general_template): Reimplement, in a more straightforward manner. (regenerate_decl_from_template): Tweak formatting. Use TMPL_ARGS_DEPTH for clarity. (set_mangled_name_for_template_decl): Use INNERMOST_ARGS. * dump.c (dequeue_and_dump): Dump information about thunks. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34384 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 31 May, 2000 1 commit
-
-
mmitchel authored
* method.c (mangle_expression): Adjust test for legal expression operators. * pt.c (instantiate_decl): Save and restore the local specializations list. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34302 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 28 May, 2000 1 commit
-
-
mmitchel authored
Mark Mitchell <mark@codesourcery.com> * cp-tree.h (ansi_opname): Make it a macro. (ansi_assopname): Likewise. (struct lang_decl_flags): Add assignment_operator_p. (struct lang_decl): Add operator_code. (DECL_VTT_PARM): Adjust. (DECL_OVERLOADED_OPERATOR_P): Return the operator_code for an overloaded operator. (SET_OVERLOADED_OPERATOR_CODE): New macro. (DECL_ASSIGNMENT_OPERATOR_P): New macro. (DECL_ARRAY_DELETE_OPERATOR_P): Adjust. (opname_tab): Remove. (assignop_tab): Likewise. (operator_name_info_t): New type. (operator_name_info): New variable. (assignment_operator_name_info): Likewise. (build_cp_library_fn): Remove declaration. (push_cp_library_fn): Likewise. (operator_name_string): Likewise. (build_decl_overload): Likewise. * call.c (print_z_candidates): Simplify. (build_object_call): Adjust usage of ansi_opname. Use DECL_OVERLOADED_OPERATOR_P. (op_error): Adjust operator name lookup. (build_conditional_expr): Adjust usage of ansi_opname. (build_new_op): Likewise. (build_op_delete_call): Likewise. (build_over_call): Likewise. (joust): Use DECL_OVERLOADED_OPERATOR_P. * decl.c (duplicate_decls): Copy operator_code. (init_decl_processing): Adjust parameters to push_cp_library_fn. (builtin_function): Adjust parameters to build_library_fn_1. (build_library_fn_1): Accept an overloaded operator code. (build_library_fn): Pass ERROR_MARK. (build_cp_library_fn): Accept an overloaded operator code. (push_cp_library_fn): Likewise. (grokfndecl): Tweak. (grokdeclarator): Simplify code to compute names of overloaded operators. Adjust use of ansi_opname. (ambi_op_p): Work on tree_codes, not identifiers. (unary_op_p): Likewise. (grok_op_properties): Likewise. (start_function): Use DECL_OVERLOADED_OPERATOR_P. (lang_mark_tree): Don't try to mark the operator_code. * decl2.c (grok_function_init): Use DECL_OVERLOADED_OPERATOR_P. * error.c (dump_decl): Remove special handling for operator names. (dump_function_name): Likewise. (dump_expr): Adjust name lookup of operators. (op_to_string): Simplify. (assop_to_string): Likewise. * init.c (build_new_1): Adjust use of ansi_opname. * lex.c (opname_tab): Remove. (assignop_tab): Likewise. (ansi_opname): Likewise. (ansi_assopname): Likewise. (operator_name_string): Likewise. (reinit_lang_specific): Likewise. (operator_name_info): New variable. (assignment_operator_name_info): Likewise. (init_operators): New function. (init_parse): Use it. (do_identifier): Adjust use of ansi_opname. * method.c (mangle_expression): Don't use ansi_opname for mangling. (build_decl_overload_real): Use DECL_OVERLOADED_OPERATOR_P. (build_decl_overload): Remove. (build_typename_overload): Use OPERATOR_TYPENAME_FORMAT directly. (do_build_assign_ref): Adjust use of ansi_opname. (synthesize_method): Likewise. (implicitly_declare_fn): Likewise. * operators.def: New file. * parse.y (operator): Adjust use of ansi_opname. * pt.c (tsubst_decl): Use IDENTIFIER_OPNAME_P. (set_mangled_name_for_template_decl): Don't play games with current_namespace. (special_function_p): Adjust use of ansi_opname. * typeck.c (check_return_expr): Likewise. * Make-lang.in (cc1plus): Depend on operators.def. * Makefile.in (lex.o): Likewise. (decl.o): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34223 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 24 May, 2000 1 commit
-
-
mmitchel authored
parameters for template functions. * pt.c (tsubst_decl): Make sure we call maybe_retrofit_in_chrg for destructors as well as constructors. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34120 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 22 May, 2000 1 commit
-
-
mmitchel authored
(DECL_CONV_FN_P): Simplify. (DECL_OPERATOR): Remove. (language_to_string): Declare. * decl.c (duplicate_decls): Fix typo in comment. (grokdeclarator): Adjust use of IDENTIFIER_TYPENAME_P. (grok_op_properties): Use DECL_CONV_FN_P instead of IDENTIFIER_TYPENAME_P. * dump.c (dequeue_and_dump): Dump the language linkage of declarations. * error.c (language_to_string): Give it external linkage. * method.c (build_typename_overload): Set IDENTIFIER_TYPENAME_P. (implicitly_declare_fn): Set DECL_LANGUAGE. * pt.c (check_explicit_specialization): Use DECL_CONV_FN_P, not IDENTIFIER_TYPENAME_P. (tsubst_decl): Likewise. (tsubst_copy): Adjust use of IDENTIFIER_TYPENAME_P. * semantics.c (finish_member_declaration): Don't mark members of classes declared in an extern "C" region as extern "C". git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@34095 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 09 May, 2000 1 commit
-
-
zack authored
* Makefile.in (WARN_CFLAGS): Add -Wwrite-strings. (tree.o): Depend on output.h. * c-decl.c (pending_invalid_xref_file, current_function_prototype_file): Constify. (pushdecl): Constify a local char *. (define_label): Constify filename parameter. * c-lex.c (init_parse): Constify parameter and return value. * c-typeck.c (c_expand_asm_operands): Constify filename parameter. * c-tree.h: Update prototypes. * c-parse.in: Constify filename member of %union, and if_stmt_file. * c-parse.y, c-parse.c, c-parse.h, objc/objc-parse.y, objc/objc-parse.c: Regenerate. * dwarfout.c (dwarfout_init): Constify main_input_filename parameter. * dwarfout.h: Update prototypes. * expr.c (expand_expr): Constify a local char *. * flags.h: Constify main_input_filename. * function.c (expand_function_end): Constify filename parameter. * genrecog.c (make_insn_sequence): Use a character array for c_test_pos. (main): Remove unused variables. * input.h: Constify input_filename, main_input_filename, and file_stack.name. Update prototypes. * output.h: Declare first_global_object_name and weak_global_object_name here, as const char *. * stmt.c (expand_asm_operands): Constify filename parameter. * toplev.c (compile_file, push_srcloc, debug_start_source_file): Constify filename parameter. (input_filename, main_input_filename): Constify. * toplev.h: Update prototypes. * tree.c: Include output.h. Don't declare first_global_object_name or weak_global_object_name. Clean up string bashing in get_file_function_name_long. * tree.h (struct tree_decl): Constify filename member. (input_filename): Constify. Update prototypes. * varasm.c (first_global_object_name, weak_global_object_name): Constify. (assemble_start_function, assemble_variable): Clean up string bashing. * gcc.c: Constify all spec-related strings initialized, transitively, from string constants. Constify all strings and string variables related to multilibs. (set_spec, read_specs): Cast argument to free to PTR. (used_arg): Do not modify multilib_matches. Use strncmp plus length comparison to compare multilib switches. * genmultilib: Constify everything declared in multilib.h. ch: * ch-tree.h: Update prototypes. Remove prototypes for functions declared elsewhere. * decl.c (define_label): Constify filename parameter. * grant.c (globalize_decl, set_default_grant_file): Constify local char * variables. Don't declare first_global_object_name or asm_out_file. * lang.c (chill_real_input_filename): Constify. * lex.c (init_parse): Constify parameter and return value. * parse.c: Don't declare input_filename. (ch_expand_asm_operands): Constify filename parameter. (parse_multi_dimension_case_action): Constify local char *. * satisfy.c (safe_satisfy_decl): Constify local char *. cp: * cp-tree.h: Constify tree_srcloc.filename, tinst_level.file, and pending_inline.filename. Update prototypes. * decl.c (define_label): Constify filename parameter. * decl2.c (warn_if_unknown_interface): Constify local char *. * input.c Constify input_source.filename. Don't declare input_filename or lineno. Constify filename parameter to feed_input. * lex.c (init_parse): Constify parameter and return value. (cp_pragma_interface, cp_pragma_implementation): Constify filename argument. (reinit_parse_for_method, reinit_parse_for_block, reinit_parse_for_expr, feed_defarg, handle_cp_pragma): Constify local char *. * pt.c: Don't declare lineno or input_filename. (print_template_context, tsubst_friend_function, tsubst_decl, tsubst, instantiate_decl): Constify local char *. * semantics.c (expand_body): Constify local char *. * tree.c (build_srcloc): Constify filename parameter. * typeck.c (c_expand_asm_operands): Constify filename parameter. f: * com.c (ffecom_subscript_check_): Constify array_name parameter. Clean up string bashing. (ffecom_arrayref_, ffecom_char_args_x_): Constify array_name parameter. (ffecom_do_entry_, ffecom_gen_sfuncdef_, ffecom_start_progunit_, ffecom_sym_transform_, ffecom_sym_transform_assign_): Constify local char *. (init_parse): Constify parameter and return value. * lex.c: Include dwarfout.h instead of prototyping dwarfout_* functions here. (ffelex_file_pop_, ffelex_file_push_): Constify filename parameter. (ffelex_hash_, ffelex_include_): Constify local char *. * std.c (ffestd_exec_end): Constify local char *. * where.c (ffewhere_file_new): Constify filename parameter. * where.h: Update prototypes. java: * check_init.c (check_init): Constify local char *. * class.c (push_class): Constify local char *. * java_tree.h: Update prototypes. * jcf-io.c (open_class): Constify filename parameter and return value. (find_class): Remove redundant string copy. Cast return from open_class. * jcf-parse.c (read_class, parse_class_file, yyparse): Constify local char *. * jcf-write.c (generate_bytecode_insns, generate_classfile): Constify local char *. * jcf.h (JCF): Constify filename and classname. (JCF_FINISH): Cast args to FREE to char * when appropriate. * lang.c (init_parse): Constify parameter and return value. * lex.c (java_get_line_col): Constify filename parameter. * parse.h: Constify parser_ctxt.filename. Update prototypes. * parse.y (java_parser_context_suspend, issue_warning_error_from_context, safe_layout_class): Constify local char *. * parse.c: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33804 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 04 May, 2000 1 commit
-
-
ghazi authored
* pt.c (tsubst_decl): Initialize variables `argvec', `gen_tmpl' and `tmpl'. * search.c (dfs_build_inheritance_graph_order): Prototype. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33678 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 01 May, 2000 1 commit
-
-
mmitchel authored
macro. * call.c (standard_conversion): Use it. (direct_reference_binding): Likewise. (build_over_call): Likewise. (is_properly_derived_from): Likewise. (compare_ics): Likewise. * class.c (resolves_to_fixed_type_p): Likewise. * optimize.c (declare_return_variable): Likewise. * pt.c (is_specialization_of): Likewise. (unify): Likewise. * typeck.c (comp_target_parms): Likeiwse. (build_static_cast): Likewise. (build_reinterpret_cast): Likewise. (build_const_cast): Likewise. (comp_ptr_ttypes_real): Likewise. (comp_ptr_ttypes_const): Likewise. * typeck2.c (process_init_constructor): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33571 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 26 Apr, 2000 1 commit
-
-
mmitchel authored
* init.c (decl_constant_value): Check TREE_READONLY_DECL_P. * call.c (convert_like_real): Don't test TREE_READONLY_DECL_P before calling decl_constant_value. * class.c (check_bitfield_decl): Likewise. * cvt.c (ocp_convert): Likewise. (convert): Likewise. * decl.c (compute_array_index_type): Likewise. (build_enumerator): Likewise. * decl2.c (check_cp_case_value): Likewise. * pt.c (convert_nontype_argument): Likewise. (tsubst): Likewise. * typeck.c (decay_conversion): Likewise. (build_compound_expr): Likewise. (build_reinterpret_cast): Likewise. (build_c_cast): Likewise. (convert_for_assignment): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33446 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 24 Apr, 2000 1 commit
-
-
mmitchel authored
(DECL_PRETTY_FUNCTION_P): Use TREE_LANG_FLAG_0, not a bit in the language-specific node. * decl.c (cp_make_fname_decl): Use build_decl, not build_lang_decl, to build the variables. (grokvardecl): Don't call build_lang_decl for local variables in templates. (grokdeclarator): Don't call build_lang_decl for local type declarations in templates. * lex.c (retrofit_lang_decl): Use ggc_alloc_obj to allocated zero'd memory, rather than calling memset. * pt.c: Include hashtab.h. (local_specializations): New variable. (retrieve_local_specialization): Use it. (register_local_specialization): Likewise. (tsubst_decl): Don't assume local variables have DECL_LANG_SPECIFIC. (instantiate_decl): Set up local_specializations. * Makefile.in (HTAB_H): New variable. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33369 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 20 Apr, 2000 1 commit
-
-
jason authored
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33269 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 11 Apr, 2000 3 commits
-
-
mmitchel authored
(complete_dtor_identifier): New macro. (CLASSTYPE_FIRST_CONVERSION): Remove. (CLASSTYPE_CONSTRUCTOR_SLOT): New macro. (CLASSTYPE_DESTRUCTOR_SLOT): Likewise. (CLASSTYPE_FIRST_CONVERSION_SLOT): Likewise. (CLASSTYPE_CONSTRUCTORS): Likewise. (CLASSTYPE_DESTRUCTORS): Likewise. (lang_decl): Add cloned_function. (DECL_COMPLETE_CONSTRUCTOR_P): New macro. (DECL_BASE_CONSTRUCTOR_P): Likewise. (DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P): Likewise. (DECL_MAYBE_IN_CHARGE_DESTRUCTOR_P): Likewise. (DECL_CLONED_FUNCTION_P): Likewise. (DECL_CLONED_FUNCTION): Likewise. (clone_function_decl): Declare. (maybe_clone_body): Likewise. * call.c (build_user_type_conversion_1): Call complete object constructors in the new ABI. (build_new_method_call): Don't add in-charge parameters under the new ABI. * class.c (add_method): Use DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P, DECL_MAYBE_IN_CHARGE_DESTRUCTOR_P, CLASSTYPE_CONSTRUCTOR_SLOT, and CLASSTYPE_DESTRUCTOR_SLOT. (build_clone): New function. (clone_function_decl): Likewise. (clone_constructors_and_destructors): Likewise. (check_bases_and_members): Use it. * decl.c (iniitialize_predefined_identifiers): Initialize complete_dtor_identifier. (finish_function): Don't add extra code to a clone. (lang_mark_tree): Mark cloned_function. * decl2.c (mark_used): Don't bother trying to instantiate things we synthesized. * dump.c (dequeue_and_dump): Don't dump CP_DECL_CONTEXT twice. * method.c (set_mangled_name_for_decl): Don't treat clones as constructors. (synthesize_method): Sythesize cloned functions, not the clones. * optimize.c (inline_data): Update comment on ret_label. (remap_block): Don't assume DECL_INITIAL exists. (copy_body_r): Allow ret_label to be NULL. (maybe_clone_body): Define. * pt.c (tsubst_decl): Handle clones. (instantiate_clone): New function. (instantiate_template): Use it. (set_mangled_name_for_template_decl): Don't treat clones as constructors. * search.c (lookup_fnfields_1): Use CLASSTYPE_CONSTRUCTOR_SLOT, CLASSTYPE_DESTRUCTOR_SLOT, and CLASSTYPE_FIRST_CONVERSION_SLOT. * semantics.c (expand_body): Clone function bodies as necessary. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33084 138bc75d-0d04-0410-961f-82ee72b054a4
-
mmitchel authored
to has_in_charge_parm_p. (DECL_CONSTRUCTOR_FOR_VBASE_P): Rename to ... (DECL_HAS_IN_CHARGE_PARM_P): ... this. (DECL_COPY_CONSTRUCTOR_P): New macro. * call.c (add_function_candidate): Use DECL_HAS_IN_CHARGE_PARM_P. (build_user_type_conversion_1): Likewise. (convert_like_real): Likewise. (build_over_call): Likeiwse. Use DECL_COPY_CONSTRUCTOR_P. * decl.c (grokdeclarator): Use DECL_HAS_IN_CHARGE_PARM_P. (copy_args_p): Likewise. (grok_ctor_properties): Likewise. (start_function): Likewise. * decl2.c (maybe_retrofit_in_charge): Likewise. Set it. * error.c (dump_function_decl): Use DECL_HAS_IN_CHARGE_PARM_P. * init.c (emit_base_init): Use DECL_COPY_CONSTRUCTOR_P. * method.c (do_build_copy_constructor): Use DECL_HAS_IN_CHARGE_PARM_P. (synthesize_method): Likewise. * pt.c (instantiate_template): Remove goto. * tree.c (build_cplus_method_type): Remove mention of obstacks in comment. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33080 138bc75d-0d04-0410-961f-82ee72b054a4
-
mmitchel authored
* decl.c (end_cleanup_fn): Adjust caller. (finish_function): Take only one parameter. * decl2.c (finish_objects): Adjust caller. (finish_static_storage_duration_function): Likewise. * method.c (emit_thunk): Likewise. * parse.y: Likewise. * parse.c: Regenerated. * pt.c (instantiate_decl): Likewise. * rtti.c (synthesize_tinfo_fn): Likewise. * semantics.c (expand_body): Likewise. * cp-tree.h (copy_decl): New function. * class.c (finish_struct_1): Use it. * lex.c (copy_decl): Define it. * pt.c (tsubst_decl): Likewise. * tree.c (copy_template_template_parm): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33079 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 10 Apr, 2000 1 commit
-
-
mmitchel authored
(DECL_MAIN_VARIANT): Remove. * decl.c (duplicate_decls): Don't set it. (start_function): Likewise. (lang_mark_tree): Don't mark it. * decl2.c (defer_fn): Don't use it. * lex.c (retrofit_lang_decl): Don't set it. * pt.c (tsubst_decl): Likewise. * ptree.c (print_lang_decl): Don't print it. * typeck.c (mark_addressable): Don't use it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@33048 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 06 Apr, 2000 2 commits
-
-
mmitchel authored
(DECL_SAVED_INLINE): Rename to ... (DECL_DEFERRED_FN): ... this. (in_function_p): Remove declaration. (mark_inline_for_output): Rename to ... (defer_fn): ... this. * decl.c (finish_function): Adjust call to mark_inline_for_output. (in_function_p): Remove definition. * decl2.c (saved_inlines): Rename to ... (deferred_fns): ... this. (saved_inlines_used): Rename to ... (deferred_fns_used): ... this. (mark_inline_for_output): Rename to ... (defer_fn): ... this. (finish_file): Adjust accordingly. (init_decl2): Likewise. * lex.c (cons_up_default_function): Likewise. * pt.c (mark_decl_instantiated): Likewise. (instantiate_decl): Don't set DECL_DEFER_OUTPUT under any circumstances. * rtti.c (get_tinfo_decl): Adjust call to mark_inline_for_output. * semantics.c (expand_body): Defer more functions. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32973 138bc75d-0d04-0410-961f-82ee72b054a4
-
mmitchel authored
* decl2.c (mark_used): Adjust call. * optimize.c (inlinable_function_p): Adjust handling of templates. * pt.c (do_decl_instantiation): Adjust call to instantiate_decl. (do_type_instantiation): Likewise. (instantiate_decl): Defer more templates. (instantiate_pending_templates): Adjust logic to handle inline friend functions. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32959 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 29 Mar, 2000 1 commit
-
-
jason authored
* pt.c (instantiate_class_template): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32794 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 27 Mar, 2000 1 commit
-
-
kenner authored
* c-decl.c (duplicate_decls): Only look at DECL_BUILT_IN_NONANSI and DECL_INLINE if FUNCTION_DECL. (pushdecl, redeclaration_error_message): Likewise, for DECL_INLINE. (store_parm_decls): Check for type of PARM_DECL being ERROR_MARK. Use DECL_WEAK, not DECL_RESULT, to flag for already seen. (combine_parm_decls): Likewise. * ggc-common.c (gcc_mark_tree_children, case 'd'): Use DECL_RESULT_FLD. * print-tree.c (print_node): Likewise. Only test DECL_PACKED, DECL_INLINE, DECL_BIT_FIELD, and DECL_TRANSPARENT_UNION on proper decl types. Properly handly DECL_INCOMING_RTL and DECL_SAVED_INSNS. * stor-layout.c (layout_decl): Only check DECL_PACKED and DECL_BIT_FIELD of FIELD_DECL. * tree.h (DECL_RESULT_FLD): New macro. * cp/class.c (check_field_decl): Fix typo. (build_vtbl_or_vbase_field): Don't clear DECL_SAVED_INSNS. (check_methods): Likewise. (check_field_decls): Likewise. Use DECL_CONTEXT, not DECL_FIELD_CONTEXT. * cp-tree.h (DECL_SHADOWED_FOR_VAR, DECL_TEMPLATE_RESULT): Use DECL_RESULT_FLD, not DECL_RESULT. * cp/decl.c (xref_tag): Use DECL_TEMPLATE_RESULT. * cp/lex.c (identifier_type): Likewise. * cp/pt.c (determine_specialization, lookup_template_class): Likewise. (tsubst_friend_function, tsubst_decl, instantiate_template): Likewise. (resolve_overloaded_unification, more_specialized): Likewise. * cp/semantics.c (finish_member_declaration): Likewise. * cp/typeck.c (build_x_function_call): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32759 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 25 Mar, 2000 2 commits
-
-
mmitchel authored
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32740 138bc75d-0d04-0410-961f-82ee72b054a4
-
mmitchel authored
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32739 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 23 Mar, 2000 1 commit
-
-
mmitchel authored
* c-common.c (decl_attributes,check_format_info,truthvalue_conversion, c_get_alias_set): Likewise. * c-decl.c (duplicate_decls): Likewise. * c-typeck.c (default_conversion,build_unary_op): Likewise. * calls.c (initialize_argument_information): Likewise. * dwarf2out.c (decl_class_context,add_abstract_origin_attribute): Likewise. * dwarfout.c (decl_class_context,output_type): Likewise. * expr.c (get_inner_reference): Likewise. * fold-const.c (simple_operand_p,fold): Likewise. * function.c (aggregate_value_p): Likewise. * stmt.c (expand_asm_operands): Likewise. * varasm.c (named_section): Likewise. * call.c (check_dtor_name,build_new_method_call): Likewise. * decl.c (push_class_binding,poplevel,pushtag,lookup_namespace_name, make_typename_type,check_initializer,cp_finish_decl,xref_tag): Likewise. * decl2.c (grokfield,build_expr_from_tree,build_expr_from_tree, decl_namespace,arg_assoc_template_arg,arg_assoc, validate_nonmember_using_decl,do_class_using_decl): Likewise. * error.c (dump_template_argument,dump_expr,cp_file_of,cp_line_of, args_to_string): Likewise. * friend.c (is_friend): Likewise. * lex.c (note_got_semicolon,note_list_got_semicolon,is_global): Likewise. * method.c (build_overload_nested_name,build_overload_value, build_qualified_name,build_qualified_name,hack_identifier): Likewise. * parse.y (typename_sub,typename_sub1): Likewise. * pt.c (push_inline_template_parms_recursive,check_template_shadow, process_partial_specialization,convert_template_argument, template_args_equal,add_pending_template,lookup_template_class, for_each_template_parm_r,maybe_fold_nontype_arg, tsubst,instantiate_template,type_unification_real,unify, instantiate_pending_templates,set_mangled_name_for_template_decl): Likewise. * repo.c (repo_get_id,repo_template_used): Likewise. * search.c (lookup_field_1): Likewise. * tree.c (walk_tree,get_type_decl,cp_tree_equal,member_p): Likewise. * xref.c (classname): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32698 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 22 Mar, 2000 1 commit
-
-
mmitchel authored
(CLASSTYPE_TI_SPEC_INFO): Likewise. * pt.c (process_partial_specialization): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32678 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 21 Mar, 2000 1 commit
-
-
nathan authored
* tree.h (COMPLETE_TYPE_P): New macro. (COMPLETE_OR_VOID_TYPE_P): New macro. (COMPLETE_OR_UNBOUND_ARRAY_TYPE_P): New macro. * stor-layout.c (layout_type, case VOID_TYPE): Don't set TYPE_SIZE. * c-aux-info.c (gen_type): Use them. * c-common.c (c_expand_expr_stmt): Likewise. * c-decl.c (poplevel, pushdecl, start_decl, finish_decl, grokdeclarator, grokparms, finish_struct, start_function, store_parm_decls, combine_parm_decls): Likewise. * c-parse.y (cast_expr): Likewise. * c-typeck.c (require_complete_type, c_sizeof, c_sizeof_nowarn, c_size_in_bytes, c_alignof, build_component_ref, build_indirect_ref, build_array_ref, convert_arguments, build_binary_op, pointer_diff, build_unary_op, digest_init: Likewise. * calls.c (initialize_argument_information): Likewise. * convert.c (convert_to_integer): Likewise. * dbxout.c (dbxout_typedefs, dbxout_type, dbxout_symbol): Likewise. * dwarfout.c (location_or_const_value_attribute, output_enumeration_type_die, output_structure_type_die, output_union_type_die, output_type): Likewise. * expr.c (safe_from_p, expand_expr): Likewise. * function.c (assign_parms): Likewise. * sdbout.c (sdbout_symbol, sdbout_one_type): Likewise. * tree.c (build_array_type, build_function_type, build_method_type, build_offset_type, build_complex_type): Likewise. * c-parse.c, c-parse.h: Regenerated. gcc/cp * typeck.c (require_complete_type, complete_type, complete_type_or_else, c_sizeof, c_sizeof_nowarn, build_array_ref, convert_arguments, pointer_diff, build_x_unary_op, build_unary_op, build_c_cast, build_modify_expr): Use COMPLETE_TYPE_P etc. * call.c (is_complete, convert_like_real, build_new_method_call): Likewise. * class.c (build_vbase_pointer_fields, check_bases, build_base_field, finish_struct_1, pushclass): Likewise. * cvt.c (cp_convert_to_pointer, convert_to_void): Likewise. * decl.c (maybe_process_template_type_declaration, pushtag, pushdecl, redeclaration_error_message, start_decl, start_decl_1, layout_var_decl, check_initializer, cp_finish_decl, grokdeclarator, require_complete_types_for_parms, grok_op_properties, xref_tag, xref_basetypes, check_function_type): Likewise. * decl2.c (check_classfn, reparse_absdcl_as_casts): Likewise. * friend.c (do_friend): Likewise. * init.c (build_offset_ref): Likewise. * parse.y (structsp): Likewise. * pt.c (maybe_process_partial_specialization, tsubst_friend_function, instantiate_class_template, tsubst, do_type_instantiation, instantiate_pending_templates): Likewise. * repo.c (repo_get_id): Likewise. * rtti.c (build_typeid, get_typeid, build_dynamic_cast_1, synthesize_tinfo_var, emit_support_tinfos): Likewise. * search.c (lookup_fnfields_1, lookup_conversions): Likewise. * semantics.c (begin_class_definition): Likewise. * tree.c (build_cplus_method_type): Likewise. * typeck2.c (digest_init, build_functional_cast, add_exception_specifier): Likewise. * parse.h, parse.c: Regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32671 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 13 Mar, 2000 1 commit
-
-
mmitchel authored
* decl.c (grokfndecl): Adjust call to revert_static_member_fn. (grok_op_properties): Likewise. (start_function): Likewise. (revert_static_member_fn): Simplify. * pt.c (check_explicit_specialization): Adjust call to revert_static_member_fn. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32501 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 12 Mar, 2000 2 commits
-
-
mmitchel authored
(tmpl_spec_kind): Likewise. (declare_pseudo_global_level): Remove. (pseudo_global_level_p): Rename to template_parm_scope_p. (pushlevel): Remove declaration. (begin_scope): New function. (finish_scope): Likewise. (current_tmpl_spec_kind): Likewise. * decl.c (struct binding_level): Shorten parm_flag to 2 bits. Shorten keep to 2 bits. Rename pseudo_global to template_parms_p. Add template_spec_p. (toplevel_bindings_p): Adjust. (declare_pseudo_global_level): Remove. (pseudo_global_level_p): Rename to template_parm_scope_p. (current_tmpl_spec_kind): New function. (begin_scope): Likewise. (finish_scope): Likewise. (maybe_push_to_top_level): Adjust. (maybe_process_template_type_declaration): Likewise. (pushtag): Likewise. (pushdecl_nonclass_level): Likewise. (lookup_tag): Likewise. (grokfndecl): Handle member template specializations. Share constructor and non-constructor code. * decl2.c (check_classfn): Handle member template specializations. * pt.c (begin_template_parm_list): Use begin_scope. (begin_specialization): Likewise. (end_specialization): Likewise. (check_explicit_specialization): Use current_tmpl_spec_kind. Handle member template specializations. (end_template_decl): Use finish_scope. Remove call to get_pending_sizes. (push_template_decl_real): Remove bogus error message. (tsubst_decl): Fix typo in code contained in comment. (instantiate_template): Handle member template specializations. (most_general_template): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32494 138bc75d-0d04-0410-961f-82ee72b054a4
-
gdr authored
* lex.c (whitespace_cr): Compress consecutive calls to warning(). (do_identifier): Ditto for error(). * pt.c (convert_nontype_argument): Ditto for cp_error(). (convert_template_argument): Ditto for cp_pedwarn(). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32492 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 11 Mar, 2000 1 commit
-
-
jason authored
* except.c (expand_end_eh_spec): Add the return type. * rtti.c (throw_bad_cast): Add the parmtypes. (throw_bad_typeid): Likewise. * semantics.c (expand_stmt): Only leave out rtl for unused artificials, and set DECL_IGNORED_P on them as well. * decl.c (wrapup_globals_for_namespace): Likewise. * decl.c (maybe_commonize_var): Skip all artificial decls. * pt.c (tsubst_decl): Don't copy TREE_ASM_WRITTEN. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32475 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 05 Mar, 2000 1 commit
-
-
mmitchel authored
expand_start_stmt_expr and expand_end_stmt_expr directly. Set RTL_EXPR_HAS_NO_SCOPE. * pt.c (instantiate_decl): Clear TI_PENDING_TEMPLATE_FLAG a little later. * dump.c (dequeue_and_dump): Dump SCOPE_NO_CLEANUPS_P. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32345 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 03 Mar, 2000 2 commits
-
-
mmitchel authored
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32302 138bc75d-0d04-0410-961f-82ee72b054a4
-
jason authored
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32297 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 29 Feb, 2000 1 commit
-
-
nathan authored
provided. (get_bindings_real): Only pass return type when necessary. Remove explicit return type check. * class.c (resolve_address_of_overloaded_function): Pass desired return type to fn_type_unification. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32253 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 22 Feb, 2000 1 commit
-
-
loewis authored
* decl.c (grokdeclarator): Change ANSI to ISO. * lex.c (consume_string, readescape, do_identifier): Likewise. (parse_float, real_yylex): Likewise. * parse.y (paren_expr_or_null, paren_cond_or_null): Likewise. (unary_expr, new_initializer, cast_expr, primary, primary_no_id, new_type_id, maybe_label_decls, simple_stmt, for.init.statement): Likewise. * pt.c (do_decl_instantiation, do_type_instantiation): Likewise. * semantics.c (finish_named_return_value): Likewise. * parse.c: Regenerate. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32100 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 20 Feb, 2000 2 commits
-
-
mmitchel authored
(get_vtable_decl): ... here, and ... (build_secondary_vtable): ... here. * pt.c (tsubst_decl): Fix formatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32082 138bc75d-0d04-0410-961f-82ee72b054a4
-
kenner authored
* c-decl.c (duplicate_decls, finish_enum): Likewise. (finish_decl): Remove -Wlarger-than code from here. * flags.h (id_clash_len): Now int. (larger_than_size): Now HOST_WIDE_INT. * fold-const.c (size_int_wide): No more HIGH parm; NUMBER is signed. Clean up checking to see if in table. (make_bit_field_ref): Remove extra parm to bitsize_int. * ggc-common.c (ggc_mark_tree_children): Mark DECL_SIZE_UNIT. * print-tree.c (print_node): Print DECL_SIZE_UNIT and TYPE_SIZE_UNIT. * stmt.c (expand_decl): Use DECL_SIZE_UNIT for stack checking size and for computing size of decl. * stor-layout.c (layout_decl): Set DECL_SIZE_UNIT. Move -Wlarger-than code to here. (layout_record): Remove extra arg to bitsize_int. Set TYPE_BINFO_SIZE_UNIT. (layout_union): Remove extra arg to bitsize_int. Use proper type for size of QUAL_UNION. (layout_type): Remove extra arg to bitsize_int. * toplev.c (id_clash_len): Now int. (larger_than_size): Now HOST_WIDE_INT. (decode_W_option): Clean up id-clash and larger-than- cases. * tree.c (get_identifier, maybe_get_identifier): Remove unneeded casts. (expr_align, case FUNCTION_DECL): DECL_ALIGN is not defined. * tree.h (BINFO_SIZE_UNIT, TYPE_BINFO_SIZE_UNIT, DECL_SIZE_UNIT): New. (struct tree_decl): New field size_unit. (size_int_wide): No HIGH operand; NUMBER is now signed. (size_int_2): Deleted. (size_int, bitsize_int): Don't use it and rework args. * varasm.c (assemble_variable, output_constructor): Use DECL_SIZE_UNIT. * ch/decl.c (layout_enum): Set DECL_SIZE_UNIT. * ch/satisfy.c (safe_satisfy_decl): Likewise. * cp/class.c (build_primary_vtable, layout_vtable_decl): Likewise. (avoid_overlap, build_base_field): Likewise. (build_base_field, build_base_fields, is_empty_class): Test DECL_SIZE with integer_zero. (layout_class_type): Set CLASSTYPE_SIZE_UNIT. * cp/cp-tree.h (struct lang_type): New field size_unit. (CLASSTYPE_SIZE_UNIT): New macro. * cp/decl.c (init_decl_processing): Set DECL_SIZE_UNIT. (cp_finish_decl): Delete -Wlarger-than processing. * cp/optimize.c (remap_decl): Walk DECL_SIZE_UNIT. * cp/pt.c (tsubst_decl): Set DECL_SIZE_UNIT. * cp/tree.c (make_binfo): binfo vector is one entry longer. (walk_tree): Walk DECL_SIZE_UNIT. * f/com.c (ffecom_sym_transform): Use DECL_SIZE_UNIT. (ffecom_transform_common_, ffecom_transform_equiv_): Likewise. (duplicate_decls): Likewise. (ffecom_tree_canonize_ptr_): Delete extra arg to bitsize_int. (finish_decl): Delete -Wlarger-than processing. * java/class.c (build_class_ref, push_super_field): Set DECL_SIZE_UNIT. * java/constants.c (build_constants_constructor): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32068 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 16 Feb, 2000 1 commit
-
-
mmitchel authored
declared, even for a virtual function. * cp-tree.h (DECL_CLASS_CONTEXT): Adjust. (DECL_FRIEND_CONTEXT): New macro. (DECL_REAL_CONTEXT): Remove. (SET_DECL_FRIEND_CONTEXT): Likewise. (DECL_VIRTUAL_CONTEXT): Adjust. (DECL_CLASS_SCOPE_P): Use TYPE_P. (add_friends): Remove. (hack_decl_function_context): Likewise. * call.c (build_new_function_call): Replace DECL_REAL_CONTEXT with CP_DECL_CONTEXT. (build_over_call): Fix indentation. Use DECL_CONTEXT instead of DECL_CLASS_CONTEXT. * class.c (dfs_build_vcall_offset_vtbl_entries): Likewise. (add_method): Set DECL_VIRTUAL_CONTEXT, not DECL_CLASS_CONTEXT. (strictly_overrides): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. (build_vtbl_or_vbase_field): Don't set DECL_CLASS_CONTEXT. (build_base_field): Likewise. (finish_struct_1): Likewise. (build_self_reference): Likewise. * decl.c (push_class_binding): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. (pushtag): Use decl_function_context, not hack_decl_function_context. (decls_match): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. (duplicate_decls): Use DECL_VIRTUAL_CONTEXT. (pushdecl): Remove bogus code. (start_decl): Use DECL_CONTEXT rather than DECL_CLASS_CONTEXT. (cp_finish_decl): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. (grokfndecl): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. Use decl_function_context, nothack_decl_function_context. (grokvardecl): Don't set DECL_CLASS_CONTEXT. (grokdeclarator): Likewise. Use decl_function_context, not hack_decl_function_context. (copy_args_p): Document. Don't use DECL_CLASS_CONTEXT. (start_function): Use DECL_FRIEND_CONTEXT, not DECL_CLASS_CONTEXT. Use decl_function_context, not hack_decl_function_context. (finish_function): Use decl_function_context, not hack_decl_function_context. (maybe_retrofit_in_chrg): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. (grokclassfn): Set DECL_VIRTUAL_CONTEXT, not DECL_CONTEXT. (finish_static_data_member_decl): Don't set DECL_CLASS_CONTEXT. (grokfield): Likewise. (finish_builtin_type): Likewise. (finish_vtable_vardec): Use decl_function_context, not hack_decl_function_context. (import_export_decl): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. (start_static_initialization_or_destruction): Likewise. (finish_static_initialization_or_destruction): Likewise. (mark_used): Adjust logic for deciding when to synthesize methods. * dump.c (dequeue_and_dump): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. * error.c (dump_function_decl): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. * friend.c (is_friend): Likewise. (add_friends): Remove. (do_friend): Use SET_DECL_FRIEND_CONTEXT. * lex.c (begin_definition_of_inclass_inline): Use decl_function_context, not hack_decl_function_context. (process_next_inline): Likewise. (do_identifier): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. * method.c (set_mangled_name_for_decl): Use DECL_CONTEXT, not DECL_CLASSS_CONTEXT. (hack_identifier): Likewise. (synthesize_method): Use decl_function_context, not hack_decl_function_context. * pt.c (template_class_depth_real): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. (is_member_template): Use decl_function_context, not hack_decl_function_context. Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. (build_template_decl): Set DECL_VIRTUAL_CONTEXT, not DECL_CLASS_CONTEXT. (check_default_tmpl_args): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. (push_template_decl_real): Likewise. (instantiate_class_template): Don't call add_friends. (tsubst_default_argument): Use DECL_CONTEXT, not DECL_REAL_CONTEXT. (tsubst_decl): Set DECL_VIRTUAL_CONTEXT, not DECL_CLASS_CONTEXT. Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. (set_meangled_name_for_template_decl): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. * repo.c (repo_inline_used): Likewise. * search.c (current_scope): Adjust for new _CONTEXT macros. (context_for_name_lookup): Use CP_DECL_CONTEXT, not DECL_REAL_CONTEXT. (friend_accessible_p): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. (lookup_fnfields_here):Likewise. (check_final_overrider): Likewise. (init_vbase_pointers): Likewise. (virtual_context): Likewise. * semantics.c (finish_member_declaration): Just set DECL_CONTEXT. (expand_body): Use decl_function_context, not hack_decl_function_context. * tree.c (hack_decl_function_context): Remove. * typeck.c (build_x_function_call): Use DECL_CONTEXT, not DECL_CLASS_CONTEXT. * typeck2.c (error_not_base_type): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@32018 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 27 Jan, 2000 1 commit
-
-
jason authored
-------------------------------------------------------------------- git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31640 138bc75d-0d04-0410-961f-82ee72b054a4
-
- 26 Jan, 2000 1 commit
-
-
ghazi authored
* class.c: Likewise. * cp-tree.h: Likewise. * cvt.c: Likewise. * decl.c: Likewise. * decl.h: Likewise. * decl2.c: Likewise. * dump.c: Likewise. * errfn.c: Likewise. * error.c: Likewise. * except.c: Likewise. * expr.c: Likewise. * init.c: Likewise. * input.c: Likewise. * lex.c: Likewise. * lex.h: Likewise. * method.c: Likewise. * optimize.c: Likewise. * parse.y: Likewise. * pt.c: Likewise. * repo.c: Likewise. * rtti.c: Likewise. * search.c: Likewise. * semantics.c: Likewise. * spew.c: Likewise. * tree.c: Likewise. * typeck.c: Likewise. * typeck2.c: Likewise. * xref.c: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31632 138bc75d-0d04-0410-961f-82ee72b054a4
-