[PATCH] Java: missing patch re-installed.

Alexandre Petit-Bianco apbianco@cygnus.com
Thu Mar 30 15:42:00 GMT 2000


I'm committing this patch. It re-installs a patch from Anthony which
seems to have disappeared.

./A

Thu Mar 30 15:26:56 2000  Alexandre Petit-Bianco  <apbianco@dcygnus.com>

	* expr.c (java_lang_expand_expr): Added Anthony's Thu Jan 6 2000
	patch missing hunk. Fixed indentation.

Index: expr.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/java/expr.c,v
retrieving revision 1.69
diff -u -p -r1.69 expr.c
--- expr.c	2000/03/25 18:34:13	1.69
+++ expr.c	2000/03/30 23:37:57
@@ -2022,8 +2022,10 @@ java_lang_expand_expr (exp, target, tmod
 	if (TREE_CONSTANT (init)
 	    && ilength >= 10 && JPRIMITIVE_TYPE_P (element_type))
 	  {
-	    tree init_decl = build_decl (VAR_DECL, generate_name (),
-					 TREE_TYPE (init));
+	    tree init_decl;
+	    push_obstacks (&permanent_obstack, &permanent_obstack);
+	    init_decl = build_decl (VAR_DECL, generate_name (),
+				    TREE_TYPE (init));
 	    pushdecl_top_level (init_decl);
 	    TREE_STATIC (init_decl) = 1;
 	    DECL_INITIAL (init_decl) = init;
@@ -2031,12 +2033,12 @@ java_lang_expand_expr (exp, target, tmod
 	    TREE_READONLY (init_decl) = 1;
 	    TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (init_decl)) = 1;
 	    make_decl_rtl (init_decl, NULL, 1);
+	    pop_obstacks ();
 	    init = init_decl;
 	  }
 	expand_assignment (build (COMPONENT_REF, TREE_TYPE (data_fld),
-				  build1 (INDIRECT_REF, array_type, array_decl),
-				  data_fld),
-			   init, 0, 0);
+				  build1 (INDIRECT_REF, array_type, 
+					  array_decl), data_fld), init, 0, 0);
 	return tmp;
       }
     case BLOCK:


More information about the Gcc-patches mailing list