aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp
diff options
context:
space:
mode:
authorDiego Novillo <dnovillo@redhat.com>2003-05-31 22:32:42 +0000
committerDiego Novillo <dnovillo@gcc.gnu.org>2003-05-31 18:32:42 -0400
commit522801e76c9547bf28f5347c0671a40d43b90302 (patch)
treea495f85b1b4b4f25bf0526997405979ef6b843a3 /gcc/cp
parentfef3106c7b8594f390ab8760328c8209cdf84384 (diff)
downloadgcc-522801e76c9547bf28f5347c0671a40d43b90302.zip
gcc-522801e76c9547bf28f5347c0671a40d43b90302.tar.gz
gcc-522801e76c9547bf28f5347c0671a40d43b90302.tar.bz2
class.c (dump_array): Call CONSTRUCTOR_ELTS to access the operand of a CONSTRUCTOR node.
* class.c (dump_array): Call CONSTRUCTOR_ELTS to access the operand of a CONSTRUCTOR node. From-SVN: r67279
Diffstat (limited to 'gcc/cp')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/class.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index ec071aeb..85c5062 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+2003-05-31 Diego Novillo <dnovillo@redhat.com>
+
+ * class.c (dump_array): Call CONSTRUCTOR_ELTS to access
+ the operand of a CONSTRUCTOR node.
+
2003-05-31 Gabriel Dos Reis <gdr@integrable-solutions.net>
* decl.c (cp_binding_level::this_entity): Rename from this_class.
diff --git a/gcc/cp/class.c b/gcc/cp/class.c
index f566384..c4887f1 100644
--- a/gcc/cp/class.c
+++ b/gcc/cp/class.c
@@ -6671,7 +6671,7 @@ dump_array (FILE * stream, tree decl)
TFF_PLAIN_IDENTIFIER));
fprintf (stream, "\n");
- for (ix = 0, inits = TREE_OPERAND (DECL_INITIAL (decl), 1);
+ for (ix = 0, inits = CONSTRUCTOR_ELTS (DECL_INITIAL (decl));
inits; ix++, inits = TREE_CHAIN (inits))
fprintf (stream, "%-4ld %s\n", (long)(ix * elt),
expr_as_string (TREE_VALUE (inits), TFF_PLAIN_IDENTIFIER));