aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2001-12-06 21:57:28 +0000
committerRichard Henderson <rth@redhat.com>2001-12-06 21:57:28 +0000
commit2da4c07f1cfa10b4590491171f7eb73932ea3a59 (patch)
tree4c19ecee5b8a7e2b662c5a6ca13c6e9fbf3c67f0
parented1801dfff5252ea5cc2e7b53ccc3e1d76d35613 (diff)
downloadgdb-2da4c07f1cfa10b4590491171f7eb73932ea3a59.zip
gdb-2da4c07f1cfa10b4590491171f7eb73932ea3a59.tar.gz
gdb-2da4c07f1cfa10b4590491171f7eb73932ea3a59.tar.bz2
* demangle.h (no_demangling): New.
(NO_DEMANGLING_STYLE_STRING): New. * cplus-dem.c (libiberty_demanglers): Add no_demangling case. (cplus_demangle): Support no_demangling.
-rw-r--r--include/ChangeLog5
-rw-r--r--include/demangle.h2
-rw-r--r--libiberty/ChangeLog5
-rw-r--r--libiberty/cplus-dem.c10
4 files changed, 22 insertions, 0 deletions
diff --git a/include/ChangeLog b/include/ChangeLog
index 4fea6f2..01e75c1 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,8 @@
+2001-12-06 Richard Henderson <rth@redhat.com>
+
+ * demangle.h (no_demangling): New.
+ (NO_DEMANGLING_STYLE_STRING): New.
+
2001-11-14 Alan Modra <amodra@bigpond.net.au>
* dis-asm.h (print_insn_i386): Declare.
diff --git a/include/demangle.h b/include/demangle.h
index a314a24..a898218 100644
--- a/include/demangle.h
+++ b/include/demangle.h
@@ -54,6 +54,7 @@
extern enum demangling_styles
{
+ no_demangling = -1,
unknown_demangling = 0,
auto_demangling = DMGL_AUTO,
gnu_demangling = DMGL_GNU,
@@ -68,6 +69,7 @@ extern enum demangling_styles
/* Define string names for the various demangling styles. */
+#define NO_DEMANGLING_STYLE_STRING "none"
#define AUTO_DEMANGLING_STYLE_STRING "auto"
#define GNU_DEMANGLING_STYLE_STRING "gnu"
#define LUCID_DEMANGLING_STYLE_STRING "lucid"
diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog
index e79260d..5546177 100644
--- a/libiberty/ChangeLog
+++ b/libiberty/ChangeLog
@@ -1,3 +1,8 @@
+2001-12-06 Richard Henderson <rth@redhat.com>
+
+ * cplus-dem.c (libiberty_demanglers): Add no_demangling case.
+ (cplus_demangle): Support no_demangling.
+
2001-11-27 Zack Weinberg <zack@codesourcery.com>
* _doprnt.c: Moved here from gcc/doprint.c. Adjust to build
diff --git a/libiberty/cplus-dem.c b/libiberty/cplus-dem.c
index e19340c..a35ff14 100644
--- a/libiberty/cplus-dem.c
+++ b/libiberty/cplus-dem.c
@@ -259,6 +259,12 @@ typedef enum type_kind_t
const struct demangler_engine libiberty_demanglers[] =
{
{
+ NO_DEMANGLING_STYLE_STRING,
+ no_demangling,
+ "Demangling disabled"
+ }
+ ,
+ {
AUTO_DEMANGLING_STYLE_STRING,
auto_demangling,
"Automatic selection based on executable"
@@ -909,6 +915,10 @@ cplus_demangle (mangled, options)
{
char *ret;
struct work_stuff work[1];
+
+ if (current_demangling_style == no_demangling)
+ return xstrdup (mangled);
+
memset ((char *) work, 0, sizeof (work));
work->options = options;
if ((work->options & DMGL_STYLE_MASK) == 0)