aboutsummaryrefslogtreecommitdiff
path: root/gcc/gimplify.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2004-06-18 22:39:14 -0700
committerRichard Henderson <rth@gcc.gnu.org>2004-06-18 22:39:14 -0700
commitff98621c682005e2a224f62c1aa5028353a5357e (patch)
tree5791e7f8af3ac3bb999dd5a105aafb41d29af09e /gcc/gimplify.c
parent048d99365055be4021508378e90a90987df38283 (diff)
downloadgcc-ff98621c682005e2a224f62c1aa5028353a5357e.zip
gcc-ff98621c682005e2a224f62c1aa5028353a5357e.tar.gz
gcc-ff98621c682005e2a224f62c1aa5028353a5357e.tar.bz2
re PR c++/16036 (Spurious "may be used uninitialized in this function" warning)
PR c++/16036 * gimple-low.c (lower_function_body): Generate return statement for fall off the end of the function here ... * tree-cfg.c (make_edges): ... instead of here. * gimplify.c (gimplify_return_expr): Mark return temp TREE_NO_WARNING. From-SVN: r83382
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r--gcc/gimplify.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index 45d5e6e..2e7d30e 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -946,6 +946,13 @@ gimplify_return_expr (tree stmt, tree *pre_p)
else
{
result = create_tmp_var (TREE_TYPE (result_decl), NULL);
+
+ /* ??? With complex control flow (usually involving abnormal edges),
+ we can wind up warning about an uninitialized value for this. Due
+ to how this variable is constructed and initialized, this is never
+ true. Give up and never warn. */
+ TREE_NO_WARNING (result) = 1;
+
gimplify_ctxp->return_temp = result;
}