diff options
author | Roger Sayle <roger@eyesopen.com> | 2006-07-15 17:19:18 +0000 |
---|---|---|
committer | Roger Sayle <sayle@gcc.gnu.org> | 2006-07-15 17:19:18 +0000 |
commit | b0d5d5de789ef8cb4df99c08c3bf864152e65e75 (patch) | |
tree | 562107b50ce0314376a0f0d968dbb168316ab365 | |
parent | 9c9309815325c3da45ec43a0949f6619788e80ad (diff) | |
download | gcc-b0d5d5de789ef8cb4df99c08c3bf864152e65e75.zip gcc-b0d5d5de789ef8cb4df99c08c3bf864152e65e75.tar.gz gcc-b0d5d5de789ef8cb4df99c08c3bf864152e65e75.tar.bz2 |
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
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/tree-gimple.c | 7 |
2 files changed, 9 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 0a7a902..02ceb92 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2006-07-15 Roger Sayle <roger@eyesopen.com> + + * 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 <kkojima@gcc.gnu.org> PR middle-end/28160 diff --git a/gcc/tree-gimple.c b/gcc/tree-gimple.c index 7b52027..b85ddad 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. */ |