summaryrefslogtreecommitdiff
path: root/libiberty/cp-demangle.c
diff options
context:
space:
mode:
authorjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>2002-02-05 16:33:31 +0000
committerjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>2002-02-05 16:33:31 +0000
commitc6d86b637864267dc54d3943ee86572dc2c7fbcf (patch)
tree421a01819111b8d1eef8a7b2067ed77dc62d91aa /libiberty/cp-demangle.c
parentec604c260e7b922d9c1509af89ad71044b653a25 (diff)
downloadgcc-c6d86b637864267dc54d3943ee86572dc2c7fbcf.tar.gz
* demangle.h (cplus_demangle_v3): Add "options" parm.
(cplus_demangle_v3_type): Remove prototype. (DMGL_VERBOSE): New macro. (DMGL_TYPES): New macro. * cplus-dem.c (flags): Add DMGL_VERBOSE (cplus_demangle_v3_p): Remove. (demangle_it): Add DMGL_TYPES to passed flags. * cp-demangle.c (cplus_demangle_v3_all): Remove. (cplus_demangle_v3_type): Remove. (cplus_demangle_v3): Add options parm. * collect2.c (dump_file): Pass DMGL_VERBOSE to cplus_demangle. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@49525 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty/cp-demangle.c')
-rw-r--r--libiberty/cp-demangle.c23
1 files changed, 5 insertions, 18 deletions
diff --git a/libiberty/cp-demangle.c b/libiberty/cp-demangle.c
index 26e20107b19..136dc723d2e 100644
--- a/libiberty/cp-demangle.c
+++ b/libiberty/cp-demangle.c
@@ -940,8 +940,6 @@ static status_t cp_demangle
PARAMS ((const char *, dyn_string_t, int));
static status_t cp_demangle_type
PARAMS ((const char*, dyn_string_t));
-static char* cplus_demangle_v3_all
- PARAMS ((const char*, int));
/* When passed to demangle_bare_function_type, indicates that the
function's return type is not encoded before its parameter types. */
@@ -3687,26 +3685,13 @@ __cxa_demangle (mangled_name, output_buffer, length, status)
If the demangling failes, returns NULL. */
char *
-cplus_demangle_v3 (mangled)
+cplus_demangle_v3 (mangled, options)
const char* mangled;
-{
- return cplus_demangle_v3_all (mangled, 0);
-}
-
-char *
-cplus_demangle_v3_type (mangled)
- const char* mangled;
-{
- return cplus_demangle_v3_all (mangled, 1);
-}
-
-static char *
-cplus_demangle_v3_all (mangled, type)
- const char* mangled;
- int type;
+ int options;
{
dyn_string_t demangled;
status_t status;
+ int type = !!(options & DMGL_TYPES);
if (mangled[0] == '_' && mangled[1] == 'Z')
/* It is not a type. */
@@ -3718,6 +3703,8 @@ cplus_demangle_v3_all (mangled, type)
return NULL;
}
+ flag_verbose = !!(options & DMGL_VERBOSE);
+
/* Create a dyn_string to hold the demangled name. */
demangled = dyn_string_new (0);
/* Attempt the demangling. */