aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/parse.y
diff options
context:
space:
mode:
authorJeff Sturm <jsturm@one-point.com>2003-11-25 17:32:54 +0000
committerJeff Sturm <jsturm@gcc.gnu.org>2003-11-25 17:32:54 +0000
commit75182467b0a33d419fd3affa859b0e48c10e012c (patch)
tree658c8162441bcbc5b5ac3ccf09f08949ff878437 /gcc/java/parse.y
parentfbe3f99721495a80dbee7c0a49009757c4f86a5b (diff)
downloadgcc-75182467b0a33d419fd3affa859b0e48c10e012c.zip
gcc-75182467b0a33d419fd3affa859b0e48c10e012c.tar.gz
gcc-75182467b0a33d419fd3affa859b0e48c10e012c.tar.bz2
re PR java/13183 ([unit-at-a-time] incorrect multidimensional array initializer with -O2)
Fix PR java/13183. * constants.c (cpool_for_class): New function. (outgoing_cpool): Remove global variable. (alloc_name_constant): Use cpool_for_class. (build_constants_constructor): Likewise. * decl.c (java_expand_body): Set current_class. * java-tree.h (outgoing_cpool) Remove declaration. (init_outgoing_cpool): Likewise. * jcf-parse.c (init_outgoing_cpool): Remove function. (parse_class_file): Don't call init_outgoing_cpool. * parse.y (java_complete_expand_methods): Don't call init_outgoing_cpool. Don't save outgoing_cpool. (java_expand_classes): Don't restore outgoing_cpool. (java_finish_classes): Likewise. From-SVN: r73926
Diffstat (limited to 'gcc/java/parse.y')
-rw-r--r--gcc/java/parse.y8
1 files changed, 0 insertions, 8 deletions
diff --git a/gcc/java/parse.y b/gcc/java/parse.y
index 5613c87..267198c 100644
--- a/gcc/java/parse.y
+++ b/gcc/java/parse.y
@@ -7689,9 +7689,6 @@ java_complete_expand_methods (tree class_decl)
current_class = TREE_TYPE (class_decl);
- /* Initialize a new constant pool */
- init_outgoing_cpool ();
-
/* Pre-expand <clinit> to figure whether we really need it or
not. If we do need it, we pre-expand the static fields so they're
ready to be used somewhere else. <clinit> will be fully expanded
@@ -7775,9 +7772,6 @@ java_complete_expand_methods (tree class_decl)
if (DECL_CONSTRUCTOR_P (decl)
&& verify_constructor_circularity (decl, decl))
break;
-
- /* Save the constant pool. We'll need to restore it later. */
- TYPE_CPOOL (current_class) = outgoing_cpool;
}
/* Attempt to create <clinit>. Pre-expand static fields so they can be
@@ -9157,7 +9151,6 @@ java_expand_classes (void)
current = TREE_CHAIN (current))
{
current_class = TREE_TYPE (TREE_VALUE (current));
- outgoing_cpool = TYPE_CPOOL (current_class);
if (flag_emit_class_files)
write_classfile (current_class);
if (flag_emit_xref)
@@ -9179,7 +9172,6 @@ java_finish_classes (void)
for (current = ctxp->class_list; current; current = TREE_CHAIN (current))
{
current_class = TREE_TYPE (current);
- outgoing_cpool = TYPE_CPOOL (current_class);
finish_class ();
}
}