diff options
author | Richard Henderson <rth@redhat.com> | 2005-05-25 16:29:54 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2005-05-25 16:29:54 -0700 |
commit | 15da280693e0d0404244096d777c74d684033ec2 (patch) | |
tree | d165fdbe45478f2cbdbec944346c757e51b525b3 | |
parent | eb2925b676cb88c2c28b5bf7484fb432f709ce88 (diff) | |
download | gcc-15da280693e0d0404244096d777c74d684033ec2.zip gcc-15da280693e0d0404244096d777c74d684033ec2.tar.gz gcc-15da280693e0d0404244096d777c74d684033ec2.tar.bz2 |
demangle.h (DEMANGLE_COMPONENT_HIDDEN_ALIAS): New.
include/
* demangle.h (DEMANGLE_COMPONENT_HIDDEN_ALIAS): New.
libiberty/
* cp-demangle.c (d_dump): Handle DEMANGLE_COMPONENT_HIDDEN_ALIAS.
(d_make_comp, d_print_comp): Likewise.
(d_special_name): Generate one.
* testsuite/demangle-expected: Add a hidden alias test.
From-SVN: r100174
-rw-r--r-- | include/ChangeLog | 4 | ||||
-rw-r--r-- | include/demangle.h | 3 | ||||
-rw-r--r-- | libiberty/ChangeLog | 7 | ||||
-rw-r--r-- | libiberty/cp-demangle.c | 14 | ||||
-rw-r--r-- | libiberty/testsuite/demangle-expected | 4 |
5 files changed, 32 insertions, 0 deletions
diff --git a/include/ChangeLog b/include/ChangeLog index 5265c31..e7eb8e0 100644 --- a/include/ChangeLog +++ b/include/ChangeLog @@ -1,3 +1,7 @@ +2005-05-25 Richard Henderson <rth@redhat.com> + + * demangle.h (DEMANGLE_COMPONENT_HIDDEN_ALIAS): New. + 2005-05-24 Gabriel Dos Reis <gdr@integrable-solutions.net> * libiberty.h (ACONCAT): Properly cast value of alloca(). diff --git a/include/demangle.h b/include/demangle.h index 944a951..304a4c4 100644 --- a/include/demangle.h +++ b/include/demangle.h @@ -239,6 +239,9 @@ enum demangle_component_type /* A reference temporary. This has one subtree, the name for which this is a temporary. */ DEMANGLE_COMPONENT_REFTEMP, + /* A hidden alias. This has one subtree, the encoding for which it + is providing alternative linkage. */ + DEMANGLE_COMPONENT_HIDDEN_ALIAS, /* A standard substitution. This holds the name of the substitution. */ DEMANGLE_COMPONENT_SUB_STD, diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog index 8f034b5..853e897 100644 --- a/libiberty/ChangeLog +++ b/libiberty/ChangeLog @@ -1,3 +1,10 @@ +2005-05-25 Richard Henderson <rth@redhat.com> + + * cp-demangle.c (d_dump): Handle DEMANGLE_COMPONENT_HIDDEN_ALIAS. + (d_make_comp, d_print_comp): Likewise. + (d_special_name): Generate one. + * testsuite/demangle-expected: Add a hidden alias test. + 2005-05-24 Gabriel Dos Reis <gdr@integrable-solutions.net> * configure.ac: Check declarations for calloc(), getenv(), diff --git a/libiberty/cp-demangle.c b/libiberty/cp-demangle.c index 856fbd4..6174439 100644 --- a/libiberty/cp-demangle.c +++ b/libiberty/cp-demangle.c @@ -520,6 +520,9 @@ d_dump (struct demangle_component *dc, int indent) case DEMANGLE_COMPONENT_REFTEMP: printf ("reference temporary\n"); break; + case DEMANGLE_COMPONENT_HIDDEN_ALIAS: + printf ("hidden alias\n"); + break; case DEMANGLE_COMPONENT_RESTRICT: printf ("restrict\n"); break; @@ -733,6 +736,7 @@ d_make_comp (struct d_info *di, enum demangle_component_type type, case DEMANGLE_COMPONENT_JAVA_CLASS: case DEMANGLE_COMPONENT_GUARD: case DEMANGLE_COMPONENT_REFTEMP: + case DEMANGLE_COMPONENT_HIDDEN_ALIAS: case DEMANGLE_COMPONENT_POINTER: case DEMANGLE_COMPONENT_REFERENCE: case DEMANGLE_COMPONENT_COMPLEX: @@ -1439,6 +1443,7 @@ d_operator_name (struct d_info *di) ::= TF <type> ::= TJ <type> ::= GR <name> + ::= GA <encoding> */ static struct demangle_component * @@ -1529,6 +1534,10 @@ d_special_name (struct d_info *di) return d_make_comp (di, DEMANGLE_COMPONENT_REFTEMP, d_name (di), NULL); + case 'A': + return d_make_comp (di, DEMANGLE_COMPONENT_HIDDEN_ALIAS, + d_encoding (di, 0), NULL); + default: return NULL; } @@ -2931,6 +2940,11 @@ d_print_comp (struct d_print_info *dpi, d_print_comp (dpi, d_left (dc)); return; + case DEMANGLE_COMPONENT_HIDDEN_ALIAS: + d_append_string_constant (dpi, "hidden alias for "); + d_print_comp (dpi, d_left (dc)); + return; + case DEMANGLE_COMPONENT_SUB_STD: d_append_buffer (dpi, dc->u.s_string.string, dc->u.s_string.len); return; diff --git a/libiberty/testsuite/demangle-expected b/libiberty/testsuite/demangle-expected index d38ce33..f8e402d 100644 --- a/libiberty/testsuite/demangle-expected +++ b/libiberty/testsuite/demangle-expected @@ -3771,3 +3771,7 @@ _Z1ZZ2Z::__CPR212____ct__Q3_3std141list__tm__128_Q2_3edm41THandle__tm__26_Q2_4em _test_array__L_1__B23b___clean.6 _test_array__L_1__B23b___clean.6 _test_array__L_1__B23b___clean.6 +# +--format=java +_ZGAN4java4lang5Class7forNameEPNS0_6StringE +hidden alias for java.lang.Class.forName(java.lang.String) |