Commit d0ea0759 by Steve Ellcey Committed by Steve Ellcey

re PR middle-end/38615 (invalid promotion to static from auto)

	PR middle-end/38615
	* gimplify.c (gimplify_init_constructor): Fix promotion of const
	variables to static.
	* doc/invoke.texi (-fmerge-all-constants): Update description.

From-SVN: r143570
parent 87673f84
2009-01-22 Steve Ellcey <sje@cup.hp.com>
PR middle-end/38615
* gimplify.c (gimplify_init_constructor): Fix promotion of const
variables to static.
* doc/invoke.texi (-fmerge-all-constants): Update description.
2009-01-22 Uros Bizjak <ubizjak@gmail.com>
PR target/38931
......
......@@ -3526,7 +3526,8 @@ gimplify_init_constructor (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p,
if (valid_const_initializer
&& num_nonzero_elements > 1
&& TREE_READONLY (object)
&& TREE_CODE (object) == VAR_DECL)
&& TREE_CODE (object) == VAR_DECL
&& (flag_merge_constants >= 2 || !TREE_ADDRESSABLE (object)))
{
if (notify_temp_creation)
return GS_ERROR;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment