This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/31150] [4.1/4.2/4.3/4.4 Regression] Not promoting an whole array to be static const
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Jul 2008 23:22:51 -0000
- Subject: [Bug middle-end/31150] [4.1/4.2/4.3/4.4 Regression] Not promoting an whole array to be static const
- References: <bug-31150-6528@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #7 from pinskia at gcc dot gnu dot org 2008-07-03 23:22 -------
(In reply to comment #4)
> http://gcc.gnu.org/ml/gcc-patches/2007-06/msg02037.html
This patch causes the following simple testcase to fail as we are stopping at
the first NULL character:
int main()
{
char str[2][34] = {"a\0c","b"};
if (str[0][2] != 'c')
__builtin_abort ();
return 0;
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31150