This is the mail archive of the
gcc-cvs@gcc.gnu.org
mailing list for the GCC project.
r187027 - in /trunk/gcc: ChangeLog c-decl.c gim...
- From: ian at gcc dot gnu dot org
- To: gcc-cvs at gcc dot gnu dot org
- Date: Tue, 01 May 2012 21:25:16 -0000
- Subject: r187027 - in /trunk/gcc: ChangeLog c-decl.c gim...
Author: ian
Date: Tue May 1 21:25:15 2012
New Revision: 187027
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=187027
Log:
gcc/:
PR c/37303
* c-decl.c (build_compound_literal): Make the decl readonly if it
an array of a readonly type.
* gimplify.c (gimplify_compound_literal_expr): Add fallback
parameter. Change all callers. If the decl is not addressable
and is not an l-value, make it readonly.
gcc/testsuite:
PR c/37303
* gcc.dg/pr37303.c: New test.
Added:
trunk/gcc/testsuite/gcc.dg/pr37303.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/c-decl.c
trunk/gcc/gimplify.c
trunk/gcc/testsuite/ChangeLog