demangle, cplus_demangle, cplus_demangle_noret - decode a C++ encoded symbol name
cc [ flag ... ] file [ library ... ] -ldemangle
#include <demangle.h> int cplus_demangle( const char *symbol, char *interpreta- tion, size_t size );
cplus_demangle() interprets (demangles) an encoded C++ linker symbol name (mangled name).
cplus_demangle_noret() does the same, except that return types for function symbols are not included in the interpretation.
Some C++ linker symbol names are not encoded. In these cases the return value is DEMANGLE_ENAME.
The symbol string parameter points to the linker symbol name.
The interpretation parameter points to a user-specified output string buffer, of size bytes.
cplus_demangle() and cplus_demangle_noret() have the following return values:
The symbol parameter is a valid encoded name and interpretation contains the decoded name.
Either the symbol parameter is not an encoded name or the symbol parameter is an incorrectly encoded name.
The content of the interpretation buffer is a copy of the content of symbol.
The interpretation output buffer is too small to contain the interpretation (either the decoded name or the linker symbol name).
The content of the interpretation buffer is undefined.
cplus_demangle() and cplus_demangle_noret() operate on names encoded by the Sun WorkShop C++ compiler versions 3.0.1, 4.0.1, 4.1, 4.2, 5.0, 5.1 and 5.2.
cplus_demangle() and cplus_demangle_noret() improve upon and replace demangle().