From 9dcc4d7a4f275af013140ff7221b9c76c66cd843 Mon Sep 17 00:00:00 2001 From: jakub Date: Mon, 5 Jul 2010 14:42:20 +0000 Subject: PR c++/44808 * gimplify.c (gimplify_modify_expr): Only SET_DECL_DEBUG_EXPR if *from_p is VAR_DECL. * g++.dg/opt/nrv16.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@161838 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/gimplify.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gcc/gimplify.c') diff --git a/gcc/gimplify.c b/gcc/gimplify.c index 5559f0e3698..4440af50b7f 100644 --- a/gcc/gimplify.c +++ b/gcc/gimplify.c @@ -4559,7 +4559,7 @@ gimplify_modify_expr (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p, /* Try to alleviate the effects of the gimplification creating artificial temporaries (see for example is_gimple_reg_rhs) on the debug info. */ if (!gimplify_ctxp->into_ssa - && DECL_P (*from_p) + && TREE_CODE (*from_p) == VAR_DECL && DECL_IGNORED_P (*from_p) && DECL_P (*to_p) && !DECL_IGNORED_P (*to_p)) -- cgit v1.2.1