Bug 35201 - libdemangle no longer distinguishes constructor/destructor variants
Summary: libdemangle no longer distinguishes constructor/destructor variants
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: demangler (show other bugs)
Version: 4.1.0
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-14 20:30 UTC by Sanjay Patel
Modified: 2016-12-18 22:35 UTC (History)
3 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2008-07-10 05:49:25


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sanjay Patel 2008-02-14 20:30:06 UTC
The C++ ABI at http://www.codesourcery.com/cxx-abi/abi.html defines:

 <ctor-dtor-name> ::= C1 # complete object constructor
     ::= C2 # base object constructor
     ::= C3 # complete object allocating constructor
     ::= D0 # deleting destructor
     ::= D1 # complete object destructor
     ::= D2 # base object destructor

However, libdemange/c++filt no longer translate those specifiers. I think this is a regression from previous revisions of the library. They used to specify "in-charge" or other strings for the various ctor/dtor flavors.

Example of raw constructor string:
_ZN9DagSymbolC2Ev
_ZN9DagSymbolC1Ev

These both are demangled as:
DagSymbol::DagSymbol()
Comment 1 Ian Lance Taylor 2008-07-10 05:49:25 UTC
Yes, the old demangler printed additional text in some cases when DMGL_VERBOSE was passed as a flag.  c++filt passes that flag.  The new demangler doesn't print that additional text.  There are several FIXME comments in libiberty/cp-demangle.c which marks the places which could or should be changed.