1. 25 Sep, 2002 1 commit
    • class.c (contains_empty_class_p): New method. · 956d9305
      	* cp/class.c (contains_empty_class_p): New method.
      	(walk_subobject_offsets): Correct computation of field offset.
      	(layout_empty_base): Correct placement of emtpy base classes.
      	(layout_class_type): Warn about ABI changes.
      
      	* doc/invoke.texi: Add more -Wabi examples.
      
      	* gcc/testsuite/g++.dg/abi/empty5.C: New test.
      	* gcc/testsuite/g++.dg/abi/empty6.C: New test.
      	* gcc/testsuite/g++.dg/abi/vbase12.C: New test.
      
      From-SVN: r57508
      Mark Mitchell committed
  2. 23 Sep, 2002 1 commit
    • c-common.c (flag_abi_version): New variable. · 2d3e278d
      	* c-common.c (flag_abi_version): New variable.
      	* c-common.h (flag_abi_version): Declare it.
      	* c-opts.c (missing_arg): Add -fabi-version.
      	(c_common_decode_option): Process -fabi-version.
      	* doc/invoke.texi (-fabi-version): Document it.
      	(-Wabi): Add information about bit-fields in unions.
      
      	* cp/class.c (layout_virtual_bases): Do not round the size of the
      	type to a multiple of the alignment before laying out virtual bases.
      	(layout_class_type): Correct handling of bit-fields that are wider
      	than their type inside unions.  Round the size of the type to a
      	even number of bytes when computing the size without virtual
      	bases.
      	* cp/cp-tree.h (abi_version_at_least): New macro.
      
      	* g++.dg/abi/bitfield6.C: New test.
      	* g++.dg/abi/bitfield7.C: New test.
      	* g++.dg/abi/bitfield8.C: New test.
      	* g++.dg/abi/vbase11.C: New test.
      
      From-SVN: r57432
      Mark Mitchell committed
  3. 21 Sep, 2002 1 commit
    • ChangeLog: Follow spelling conventions. · 838dfd8a
      	* ChangeLog: Follow spelling conventions.
      	* ChangeLog.2: Likewise.
      	* call.c: Likewise.
      	* class.c: Likewise.
      	* cp-tree.h: Likewise.
      	* cvt.c: Likewise.
      	* decl.c: Likewise.
      	* decl2.c: Likewise.
      	* except.c: Likewise.
      	* friend.c: Likewise.
      	* g++spec.c: Likewise.
      	* init.c: Likewise.
      	* lex.c: Likewise.
      	* mangle.c: Likewise.
      	* method.c: Likewise.
      	* operators.def: Likewise.
      	* optimize.c: Likewise.
      	* pt.c: Likewise.
      	* rtti.c: Likewise.
      	* search.c: Likewise.
      	* semantics.c: Likewise.
      	* spew.c: Likewise.
      	* tree.c: Likewise.
      	* typeck.c: Likewise.
      
      From-SVN: r57387
      Kazu Hirata committed
  4. 19 Sep, 2002 1 commit
    • cp-tree.h: New prototype for walk_vtabls(). · 70b76b34
       2002-09-19  Devang Patel  <dpatel@apple.com>
             * cp/cp-tree.h: New prototype for walk_vtabls().
             * cp/decl.c (walk_vtables_r): New function.
             (struct cp_binding_level): Add new members, namespaces,
             names_size and vtables.
             (add_decl_to_level): Add decl in namespaces or vtables
             chain, if conditions match.
             (walk_vtables): New function.
             (walk_namespaces_r): Travers separate namespace chain
             for namespace decls.
             (wrapup_globals_for_namespace): Use names_size instead
             of list_length().
             * cp/decl2.c (finish_file): Use walk_vtables() instead of
             walk_globals() to walk vtable decls.
      
      From-SVN: r57305
      Devang Patel committed
  5. 18 Sep, 2002 1 commit
  6. 17 Sep, 2002 1 commit
    • Makefile.am (CFILES): Add cxxfilt.c. · f989ed67
      binutils:
      	* Makefile.am (CFILES): Add cxxfilt.c.
      	(cxxfilt_SOURCES): Now just cxxfilt.c $(BULIBS).
      	(cxxfilt_LDADD): Delete.
      	Remove all references to underscore.c.
      	Regen dependencies.
      	* configure.in: Define TARGET_PREPENDS_UNDERSCORE in
      	config.h from $UNDERSCORE, rather than AC_SUBSTing it.
      	* binutils/cxxfilt.c: Moved here from gcc/cp, minor
      	adjustments to fit into binutils framework.
      	* configure, config.in, Makefile.in, doc/Makefile.in: Regenerate.
      
      gcc/cp:
      	* Make-lang.in: Remove all references to the demangler.
      	* cxxfilt.c: Moved to binutils.
      
      From-SVN: r57235
      Zack Weinberg committed
  7. 16 Sep, 2002 5 commits
    • re PR c++/7718 ('complex' template instantiation causes internal compiler error (gcc 3.1, gcc 3.2)) · 3ec83083
      cp:
      	PR c++/7718
      	* pt.c (tsubst_decl): Remove assert.
      testsuite:
      	* g++.dg/template/subst1.C: New test.
      
      From-SVN: r57211
      Nathan Sidwell committed
    • Remove DR 295 implementation. · 171d2f50
      cp:
      	Remove DR 295 implementation.
      	* pt.c (check_cv_quals_for_unify): Disable function & method cases.
      	* tree.c (cp_build_qualified_type_real): Likewise. Don't warn
      	about ignoring volatile qualifiers.
      
      	* search.c (lookup_member): Correct documentation.
      testsuite:
      	* g++.dg/template/qualttp20.C: Adjust expected errors.
      	* g++.old-deja/g++.jason/report.C: Likewise.
      	* g++.old-deja/g++.other/qual1.C: Likewise.
      
      From-SVN: r57209
      Nathan Sidwell committed
    • Index: gcc/ChangeLog · 36a5eadd
      2002-09-12  Geoffrey Keating  <geoffk@apple.com>
      
      	* ggc-common.c (ggc_mark_rtx_children_1): Update for changed name
      	mangling.
      
      	The following changes are merged from pch-branch:
      
      	* doc/gty.texi (GTY Options): Document %a.
      	* gengtype.c (do_scalar_typedef): New function.
      	(process_gc_options): Handle `length' option.
      	(set_gc_used_type): A pointer to an array of structures doesn't
      	qualify as a pointer to a structure.
      	(output_escaped_param): Add `%a' escape.
      	(write_gc_structure_fields): Allow 'desc' on array of unions.
      	(main): Define `uint8', `jword' and `JCF_u2' as scalars; use
      	do_scalar_typedef.
      
      	* gengtype.c (enum rtx_code): Make global.
      	(rtx_format): Make global.
      	(rtx_next): New.
      	(gen_rtx_next): New.
      	(write_rtx_next): New.
      	(adjust_field_rtx_def): Skip fields marked by chain_next.
      	(open_base_files): Delete redundant prototype.
      	(write_enum_defn): New.
      	(output_mangled_typename): Correct abort call.
      	(write_gc_marker_routine_for_structure): Handle chain_next and
      	chain_prev options.
      	(finish_root_table): Don't output redundant \n.
      	(main): Call gen_rtx_next, write_rtx_next, write_enum_defn.
      	* c-tree.h (union lang_tree_node): Add chain_next option.
      
      	* gengtype.h (NUM_PARAM): New definition.
      	(struct type): For TYPE_PARAM_STRUCT, allow multiple parameters.
      	* gengtype.c (find_param_structure): New.
      	(adjust_field_type): Handle param<n>_is option.
      	(process_gc_options): Detect use_params option.  Update callers.
      	(set_gc_used_type): Add 'param' parameter, update callers.  Handle
      	'use_params' option.
      	(open_base_files): Add splay-tree.h to list of files included.
      	(output_mangled_typename): New.
      	(write_gc_structure_fields): Update 'param' parameter to support
      	multiple parameters.  Change name mangling.  Allow parameterized
      	fields to have an apparent scalar type.  Handle param<n>_is options,
      	use_param option.
      	(write_gc_marker_routine_for_structure): Update for change to name
      	mangling.  Better guess the output file for parameterized types.
      	(write_gc_types): Update for change to name mangling.
      	(write_gc_root): Update for change to name mangling.  Handle (ignore)
      	param<n>_is options.
      	* doc/gty.texi (GTY Options): Add description of param<n>_is
      	options, use_params option.
      	* ggc.h (ggc_mark_rtx): Update for changed name mangling.
      	* gengtype-lex.l: Produce token for param<n>_is.
      	* gengtype-yacc.y: Parse param<n>_is.
      
      	* gengtype.c (adjust_field_tree_exp): Don't name a variable 'rindex'.
      
      	* rtl.c: Update comment describing rtx_format.
      	* rtl.h (union rtunion): Separate definition and typedef.
      	(struct rtx_def): Use gengtype to mark.
      	* Makefile.in (gengtype.o): Also depend on rtl.def.
      	* ggc.h (ggc_mark_rtx_children): Delete prototype.
      	(ggc_mark_rtx): Change to alias of gengtype-generated routine.
      	* ggc-common.c (ggc_mark_rtx_children): Delete.
      	(ggc_mark_rtx_children_1): Delete.
      	(gt_ggc_m_rtx_def): Delete.
      	* gengtype.c (adjust_field_rtx_def): New.
      	(adjust_field_type): Call adjust_field_rtx_def.
      	(write_gc_structure_fields): Add 'default' case to switch if none
      	is specified; remove unused code.
      
      	* tree.h (struct tree_exp): Update for change to meaning
      	of special.
      	* gengtype.c (adjust_field_tree_exp): New function.
      	(adjust_field_type): Handle `tree_exp' special here.
      	(write_gc_structure_fields): Don't handle `tree_exp' special here.
      	Handle new `dot' option.
      
      	* gengtype.h: Make `info' a pointer-to-const.
      	* gengtype-yacc.y (yacc_ids): Use xasprintf.
      
      	* gengtype.c (write_gc_structure_fields): Remove implementation
      	of `always' option, add `default' option.
      	* doc/gty.texi (GTY Options): Remove documentation of `always',
      	add `default'.
      
      Index: gcc/cp/ChangeLog
      2002-09-12  Geoffrey Keating  <geoffk@apple.com>
      
      	* cp-tree.h (union lang_tree_node): Add chain_next option.
      
      Index: gcc/f/ChangeLog
      2002-09-12  Geoffrey Keating  <geoffk@apple.com>
      
      	* com.c (union lang_tree_node): Add chain_next option.
      
      Index: gcc/java/ChangeLog
      2002-09-12  Geoffrey Keating  <geoffk@apple.com>
      
      	* java-tree.h (union lang_tree_node): Add chain_next option.
      
      From-SVN: r57206
      Geoffrey Keating committed
    • parse.y (parse_finish_call_expr): Check lookup_member result. · 7979434d
      cp:
      	* parse.y (parse_finish_call_expr): Check lookup_member result.
      testsuite:
      	* g++.dg/lookup/scoped2.C: New test.
      
      From-SVN: r57195
      Nathan Sidwell committed
    • re PR c++/7015 (certain __asm__ constructs rejected) · 28c56d25
      cp:
      2002-09-16  Nathan Sidwell  <nathan@codesourcery.com>
      
      	PR c++/7015
      	* semantic.c (finish_asm_stmt): Fix operand/output_operands
      	thinko.
      	* typeck.c (c_expand_asm_operands): Protect from error_mark_node.
      testsuite
      	* g++.dg/ext/asm3.C: New test.
      
      From-SVN: r57192
      Nathan Sidwell committed
  8. 15 Sep, 2002 2 commits
  9. 14 Sep, 2002 3 commits
  10. 13 Sep, 2002 4 commits
  11. 11 Sep, 2002 1 commit
    • Makefile.in: Remove all references to s-under and underscore.c. · 3fd9d606
      gcc:
      	* Makefile.in: Remove all references to s-under and underscore.c.
      	* collect2.c, tlink.c: Change all uses of prepends_underscore
      	to look directly at USER_LABEL_PREFIX.
      
      gcc/cp:
      	* Make-lang.in: Build cp/cxxfilt.o from $(srcdir)/cp/cxxfilt.c,
      	and c++filt from cxxfilt.o + version.o + $(LIBDEPS).
      	* cxxfilt.c: New file: split from libiberty/cplus-dem.c, with
      	minor adjustments (use version_string, eliminate yet another
      	duplicate of xmalloc)
      
      libiberty:
      	* cplus-dem.c: Code code under #ifdef MAIN moved to gcc/cp/cxxfilt.c.
      	* testsuite/Makefile.in: Adjust for test-demangle.
      	* testsuite/regress-demangle: Deleted.
      	* testsuite/test-demangle.c: New file.
      	* testsuite/demangle-expected: Change \$ to $ throughout, now that
      	this file is not being read by a shell script.
      
      From-SVN: r57037
      Zack Weinberg committed
  12. 09 Sep, 2002 1 commit
  13. 04 Sep, 2002 2 commits
  14. 01 Sep, 2002 1 commit
  15. 31 Aug, 2002 2 commits
  16. 27 Aug, 2002 1 commit
    • c-common.c (warn_abi): New variable. · eca7f13c
      	* c-common.c (warn_abi): New variable.
      	* c-common.h (warn_abi): Likewise.
      	* c-opts.c (COMMAND_LINE_OPTIONS): Add -Wabi.
      	(c_common_decode_option): Handle it.
      	* doc/invoke.texi:P Document -Wabi.
      
      	* class.c (layout_virtual_bases): Warn about bugs in G++ that
      	result in incorrect object layouts.
      	(layout_class_type): Likewise.
      
      	* testsuite/g++.dg/abi/bitfield5.C: New test.
      	* testsuite/g++.dg/abi/vbase10.C: Likewise.
      
      From-SVN: r56618
      Mark Mitchell committed
  17. 25 Aug, 2002 1 commit
    • tree.c (lvalue_p_1): Add argument for whether casts of lvalues are allowable. · 13d3f0b6
      2002-08-24  Matt Austern  <austern@apple.com>
      
              * tree.c (lvalue_p_1): Add argument for whether casts of lvalues
              are allowable.
              (real_lvalue_p): Update caller.
              (lvalue_p): Ditto.
              (non_cast_lvalue_or_else): New.
              * tree.h: Declare it.
              * typeck.c (build_unary_op): Use non_cast_lvalue_or_else.
      
      2002-08-24  Matt Austern  <austern@apple.com>
      
              * g++.dg/ext/lvaddr.C: New test.
              * g++.dg/ext/lvcast.C: New test.
      
      From-SVN: r56560
      Matt Austern committed
  18. 23 Aug, 2002 1 commit
  19. 22 Aug, 2002 1 commit
    • c-common.h (RETURN_STMT_EXPR): Rename from RETURN_EXPR. · d65b1d77
              * c-common.h (RETURN_STMT_EXPR): Rename from RETURN_EXPR.
              * c-common.def: Adjust.
              * c-dump.c (c_dump_tree): Adjust.
              * c-semantics.c (genrtl_return_stmt): Adjust.
              * c-pretty-print.c (pp_c_statement): Adjust.
              * tree-inline.c (copy_body_r): Adjust.
      
      2002-08-22  Jason Merrill  <jason@redhat.com>
      
              * pt.c (tsubst_expr): RETURN_EXPR is now RETURN_STMT_EXPR.
              * semantics.c (nullify_returns_r): Likewise.
      
      From-SVN: r56523
      Jason Merrill committed
  20. 17 Aug, 2002 2 commits
  21. 15 Aug, 2002 3 commits
  22. 13 Aug, 2002 1 commit
  23. 11 Aug, 2002 2 commits
  24. 10 Aug, 2002 1 commit
    • c-opts.c (set_std_cxx98, [...]): New. · f749a36b
      	* c-opts.c (set_std_cxx98, set_std_c89): New.
      	(COMMAND_LINE_OPTIONS): Move more from cppinit.c.
      	(c_common_decode_option): Handle new switches from cppinit.c.
      	Add -std=gnu++98.
      	* cppinit.c (set_lang): Rename cpp_set_lang.  Export.
      	(no_arg, no_num): Remove.
      	(COMMAND_LINE_OPTIONS): Move more to c-opts.c.  Drop all lang-
      	switches apart from -lang-objc and lang-asm.
      	(cpp_handle_option): Similarly.
      	* cpplib.h (cpp_set_lang): New.
      	* doc/cppopts.texi, doc/invoke.texi: Document -std=c++98,
      	-std=gnu++98.
      	* objc/lang-specs.h: Remove -ansi.
      cp:
      	* lang-specs.h: Remove -ansi.
      
      From-SVN: r56185
      Neil Booth committed