This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RFA: Don't pass DMGL_VERBOSE to cplus_demangle() when testing.

The libiberty demangler testsuite passes DMGL_VERBOSE to
cplus_demangle().  This makes no difference for the older demangler
code.  For the newer v3 demangler, it causes the demangler to generate
more verbose output.

The testsuite, however, expects the less verbose output.  For example,
consider this test 

void operator-<42>(A<(42) + (2)>::T)

When the demangler is invoked without DMGL_VERBOSE, it produces this

void operator-<42>(A<(42)+(2)>::T)

which is identical to the expected result except for inconsequential

When the demangler is invoked with DMGL_VERBOSE, it produces this

void operator-<(int)42>(A<((int)42)+((int)2)>::T)

We need to either not use DMGL_VERBOSE, or change some of the expected
tests.  Since the C++ version of the demangler generates the result
found in demangle-expected, I think the simplest approach is to not
pass DMGL_VERBOSE to cplus_demangle().

This is done in the appended trivial patch.


2003-11-18  Ian Lance Taylor  <>

	* testsuite/test-demangle.c (main): Don't pass DMGL_VERBOSE to

Index: test-demangle.c
RCS file: /cvs/gcc/gcc/libiberty/testsuite/test-demangle.c,v
retrieving revision 1.2
diff -u -r1.2 test-demangle.c
--- test-demangle.c	5 Jun 2003 16:38:22 -0000	1.2
+++ test-demangle.c	18 Nov 2003 17:21:03 -0000
@@ -146,7 +146,7 @@
       cplus_demangle_set_style (style);
       result = cplus_demangle (,
       if (result
 	  ? strcmp (result,

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]