diff options
-rw-r--r-- | libiberty/ChangeLog | 4 | ||||
-rw-r--r-- | libiberty/cplus-dem.c | 24 |
2 files changed, 28 insertions, 0 deletions
diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog index aca683defa1..63cfef347f0 100644 --- a/libiberty/ChangeLog +++ b/libiberty/ChangeLog @@ -1,3 +1,7 @@ +1998-11-16 Benjamin Kosnik <bkoz@haight.constant.com> + + * cplus-dem.c (demangle_fund_type): Add demangling for C9x types. + Thu Nov 19 22:15:50 1998 Jeffrey A Law (law@cygnus.com) * mpw.c (mpw_access): Add missing parens. diff --git a/libiberty/cplus-dem.c b/libiberty/cplus-dem.c index 5ccf92ffa7b..05026c1da4e 100644 --- a/libiberty/cplus-dem.c +++ b/libiberty/cplus-dem.c @@ -2883,6 +2883,8 @@ demangle_fund_type (work, mangled, result) { int done = 0; int success = 1; + char buf[10]; + int dec = 0; string btype; type_kind_t tk = tk_integral; @@ -3000,6 +3002,28 @@ demangle_fund_type (work, mangled, result) success = 0; break; } + case 'I': + ++(*mangled); + if (**mangled == '_') + { + int i; + ++(*mangled); + for (i = 0; **mangled != '_'; ++(*mangled), ++i) + buf[i] = **mangled; + buf[i] = '\0'; + ++(*mangled); + } + else + { + strncpy (buf, *mangled, 2); + *mangled += 2; + } + sscanf (buf, "%x", &dec); + sprintf (buf, "int%i_t", dec); + APPEND_BLANK (result); + string_append (result, buf); + break; + /* fall through */ /* An explicit type, such as "6mytype" or "7integer" */ case '0': |