This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] Remove unnecessary case labels from build1_stat
- From: Richard Guenther <rguenth at tat dot physik dot uni-tuebingen dot de>
- To: gcc-patches at gcc dot gnu dot org
- Date: Wed, 18 May 2005 16:52:24 +0200 (CEST)
- Subject: [PATCH] Remove unnecessary case labels from build1_stat
This removes two-operand tree codes from the switch. We even
have an appropriate assert above.
Ok for mainline?
Richard.
2005-05-18 Richard Guenther <rguenth@gcc.gnu.org>
* tree.c (build1_stat): Don't try to handle two-operand
tree codes.
Index: tree.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree.c,v
retrieving revision 1.479
diff -c -3 -p -r1.479 tree.c
*** tree.c 11 May 2005 16:25:29 -0000 1.479
--- tree.c 18 May 2005 14:49:42 -0000
*************** build1_stat (enum tree_code code, tree t
*** 2536,2548 ****
TREE_SIDE_EFFECTS (t) = 1;
else switch (code)
{
- case INIT_EXPR:
- case MODIFY_EXPR:
case VA_ARG_EXPR:
- case PREDECREMENT_EXPR:
- case PREINCREMENT_EXPR:
- case POSTDECREMENT_EXPR:
- case POSTINCREMENT_EXPR:
/* All of these have side-effects, no matter what their
operands are. */
TREE_SIDE_EFFECTS (t) = 1;
--- 2536,2542 ----