From: Roger Sayle Date: Sat, 15 Jul 2006 17:19:18 +0000 (+0000) Subject: tree-gimple.c (is_gimple_stmt): Sink test of IS_EMPTY_STMT into a new NOP_EXPR case... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b0d5d5de789ef8cb4df99c08c3bf864152e65e75;p=gcc.git tree-gimple.c (is_gimple_stmt): Sink test of IS_EMPTY_STMT into a new NOP_EXPR case of the switch statement. * tree-gimple.c (is_gimple_stmt): Sink test of IS_EMPTY_STMT into a new NOP_EXPR case of the switch statement. From-SVN: r115480 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 0a7a902eef6..02ceb92e9b5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2006-07-15 Roger Sayle + + * tree-gimple.c (is_gimple_stmt): Sink test of IS_EMPTY_STMT into + a new NOP_EXPR case of the switch statement. + 2006-07-15 Kaz Kojima PR middle-end/28160 diff --git a/gcc/tree-gimple.c b/gcc/tree-gimple.c index 7b5202771c3..b85ddad45fe 100644 --- a/gcc/tree-gimple.c +++ b/gcc/tree-gimple.c @@ -193,11 +193,12 @@ is_gimple_stmt (tree t) { enum tree_code code = TREE_CODE (t); - if (IS_EMPTY_STMT (t)) - return 1; - switch (code) { + case NOP_EXPR: + /* The only valid NOP_EXPR is the empty statement. */ + return IS_EMPTY_STMT (t); + case BIND_EXPR: case COND_EXPR: /* These are only valid if they're void. */