summaryrefslogtreecommitdiff
path: root/libiberty/cplus-dem.c
diff options
context:
space:
mode:
authorDJ Delorie <dj@delorie.com>2001-02-02 18:58:51 +0000
committerDJ Delorie <dj@delorie.com>2001-02-02 18:58:51 +0000
commit8f31c728e5edbe3cc7693c5dca43f3da766dbb6b (patch)
treecd2b05e7b607af1dc4e3411e2857e6820038b054 /libiberty/cplus-dem.c
parentd9bcfab2edcf841499f509a820684c09e3cf2f2d (diff)
downloadgdb-8f31c728e5edbe3cc7693c5dca43f3da766dbb6b.tar.gz
merge from gcc
Diffstat (limited to 'libiberty/cplus-dem.c')
-rw-r--r--libiberty/cplus-dem.c20
1 files changed, 11 insertions, 9 deletions
diff --git a/libiberty/cplus-dem.c b/libiberty/cplus-dem.c
index a42f45e6426..d49ec7c7e1d 100644
--- a/libiberty/cplus-dem.c
+++ b/libiberty/cplus-dem.c
@@ -1,6 +1,6 @@
/* Demangler for GNU C++
Copyright 1989, 1991, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000 Free Software Foundation, Inc.
+ 2000, 2001 Free Software Foundation, Inc.
Written by James Clark (jjc@jclark.uucp)
Rewritten by Fred Fish (fnf@cygnus.com) for ARM and Lucid demangling
Modified by Satish Pai (pai@apollo.hp.com) for HP demangling
@@ -922,6 +922,13 @@ cplus_demangle (mangled, options)
return ret;
}
+ if (JAVA_DEMANGLING)
+ {
+ ret = java_demangle_v3 (mangled);
+ if (ret)
+ return ret;
+ }
+
if (GNAT_DEMANGLING)
return ada_demangle(mangled,options);
@@ -4950,7 +4957,6 @@ static struct option long_options[] = {
{"strip-underscores", no_argument, 0, '_'},
{"format", required_argument, 0, 's'},
{"help", no_argument, 0, 'h'},
- {"java", no_argument, 0, 'j'},
{"no-strip-underscores", no_argument, 0, 'n'},
{"version", no_argument, 0, 'v'},
{0, no_argument, 0, 0}
@@ -5044,12 +5050,13 @@ main (argc, argv)
char *result;
int c;
const char *valid_symbols;
+ enum demangling_styles style;
program_name = argv[0];
strip_underscore = prepends_underscore;
- while ((c = getopt_long (argc, argv, "_ns:j", long_options, (int *) 0)) != EOF)
+ while ((c = getopt_long (argc, argv, "_ns:", long_options, (int *) 0)) != EOF)
{
switch (c)
{
@@ -5067,13 +5074,8 @@ main (argc, argv)
case '_':
strip_underscore = 1;
break;
- case 'j':
- flags |= DMGL_JAVA;
- break;
case 's':
{
- enum demangling_styles style;
-
style = cplus_demangle_name_to_style (optarg);
if (style == unknown_demangling)
{
@@ -5146,7 +5148,7 @@ main (argc, argv)
skip_first = i;
mbuffer[i] = 0;
-
+ flags |= style;
result = cplus_demangle (mbuffer + skip_first, flags);
if (result)
{