This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Java: parse.y fix


Recently an extra check was added to build1 which causes it to ICE when
called for a non-unary tree node. This changes Java to use build instead
of build1 when constructing a "null-ary" node.

I'm checking this in as an obvious fix since libjava won't build without
it.

regards

  [ bryce ]

2001-01-05  Bryce McKinlay  <bryce@albatross.co.nz>

	From patha@softlab.ericsson.se:
	* parse.y (switch_label): Use build, not build1, to construct 
	DEFAULT_EXPR.

Index: parse.y
===================================================================
RCS file: /cvs/gcc/egcs/gcc/java/parse.y,v
retrieving revision 1.238
diff -u -r1.238 parse.y
--- parse.y	2000/12/18 21:23:02	1.238
+++ parse.y	2001/01/06 04:58:58
@@ -1628,7 +1628,7 @@
 		}
 |	DEFAULT_TK REL_CL_TK
 		{ 
-		  tree lab = build1 (DEFAULT_EXPR, NULL_TREE, NULL_TREE);
+		  tree lab = build (DEFAULT_EXPR, NULL_TREE, NULL_TREE);
 		  EXPR_WFL_LINECOL (lab) = $1.location;
 		  java_method_add_stmt (current_function_decl, lab);
 		}

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]