summaryrefslogtreecommitdiff
path: root/gcc/tree-inline.c
diff options
context:
space:
mode:
authordodji <dodji@138bc75d-0d04-0410-961f-82ee72b054a4>2009-08-10 07:16:08 +0000
committerdodji <dodji@138bc75d-0d04-0410-961f-82ee72b054a4>2009-08-10 07:16:08 +0000
commit29f90295efc6e5f029a3cadad89f017e856b8384 (patch)
tree312390e4e32b0a73b1c7dd7e92037b77a86af30b /gcc/tree-inline.c
parent2db66e7c42fa26176354d8406151e782feeed203 (diff)
downloadgcc-29f90295efc6e5f029a3cadad89f017e856b8384.tar.gz
2009-08-10 Dodji Seketeli <dodji@redhat.com>
gcc/ChangeLog: PR c++/40866 * tree-inline.c (copy_statement_list): The resulting copy shouldn't loose the original type of the statement list. gcc/testsuite/ChangeLog: PR c++/40866 * g++.dg/expr/stmt-expr-1.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@150615 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-inline.c')
-rw-r--r--gcc/tree-inline.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/tree-inline.c b/gcc/tree-inline.c
index f79ba758088..3b07aaa36ba 100644
--- a/gcc/tree-inline.c
+++ b/gcc/tree-inline.c
@@ -600,6 +600,7 @@ copy_statement_list (tree *tp)
new_tree = alloc_stmt_list ();
ni = tsi_start (new_tree);
oi = tsi_start (*tp);
+ TREE_TYPE (new_tree) = TREE_TYPE (*tp);
*tp = new_tree;
for (; !tsi_end_p (oi); tsi_next (&oi))