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
* testsuite/demangle-expected: Add test case for infinite loop in
demangler.
* cplus-dem.c (demangle_arm_hp_template): Stop trying to demangle
if do_type() doesn't make any progress --- prevents an infinite
loop.
From-SVN: r49875
2002-02-18 Carlo Wood <carlo@gnu.org>
PR c++/5390
* cplus-dem.c (demangle_integral_value): Accept multi-digit
numbers that do not start with an underscore; This is needed
for integer template parameters. This doesn't break anything
because multi-digit numbers are never followed by a digit.
* testsuite/demangle-expected: Corrected all mangled test
cases with multi-digit template parameters: g++ 2.95.x does
not generate underscores around these parameters.
From-SVN: r49851
2002-02-02 H.J. Lu (hjl@gnu.org)
* cp-demangle.c (cp_demangle_type): Do not protect with
IN_LIBGCC2.
(cplus_demangle_v3_all): New.
(cplus_demangle_v3): Call cplus_demangle_v3_all.
(cplus_demangle_v3_type): Call cplus_demangle_v3_all.
* cplus-dem.c (cplus_demangle_v3_p): New function pointer.
Initialized to cplus_demangle_v3.
(cplus_demangle_with_style): Call cplus_demangle_v3_p instead
of cplus_demangle_v3.
(main): Set cplus_demangle_v3_p to cplus_demangle_v3_type for
command line symbol.
* testsuite/regress-demangle: Pass the mangled name at the
command line.
From-SVN: r49456
2002-01-30 Phil Edwards <pme@gcc.gnu.org>
* cp-demangle.c (cp_demangle_type): Do not protect with IN_LIBGCC2.
(cplus_demangle_v3): Mimic __cxa_demangle and fall back on
cp_demangle_type.
* testsuite/demangle-expected: New gnu-v3 test.
From-SVN: r49353
* cp-demangle.c (NAMESPACE_SEPARATOR): New define.
(struct demangling_def): Add `style' field.
(demangling_new): New parameter `style'. Set it in demangling_t.
(demangle_prefix): Use NAMESPACE_SEPARATOR.
(demangle_type_ptr): Don't emit pointer symbol if doing Java output.
(cp_demangle): New parameter `style'. Pass it to demangling_new().
(main): Call cp_demangle with extra parameter.
(java_demangle_v3): New function.
(java_builtin_type_names): New. Table of primitive type names used
for Java demangling.
(demangle_builtin_type): Look up in java_builtin_type_names if doing
Java output.
* cplus-dem.c (cplus_demangle): Use java_demangle_v3 to do Java
demangling.
(long_options): Remove obsolete `java' option.
(main): Remove explicit handling of `java' option. Instead, pass style
parameter in cplus_demangle flags as gdb does.
* testsuite/demangle.expected: Add some Java test cases.
From-SVN: r39399
* testsuite/demangle-expected: Add four tests for type_info
mangling.
* cplus-dem.c (gnu_special): Use do_type, not demangle_fund_type,
for a non-template non-qualified type_info function or node.
From-SVN: r36301
* cplus-dem.c (INTBUF_SIZE): New macro.
(string_append_template_idx): New function.
(demangle_expression): Likewise.
(demangle_integral_value): Use it.
(demangle_real_value): New function, split out from ...
(demangle_template_value_parm): ... here. Use
string_append_template_idx. Use demangle_real_value.
(demangle_template): Use string_append_template_idx.
(demangle_qualified): Use consume_count_with_underscores.
(get_count): Tweak formatting.
(do_type): Use string_append_template_idx.
From-SVN: r30091