This is the mail archive of the
mailing list for the GCC project.
Re: PR 2765
- To: Mark Mitchell <mark at codesourcery dot com>
- Subject: Re: PR 2765
- From: "Joseph S. Myers" <jsm28 at cam dot ac dot uk>
- Date: Sun, 20 May 2001 00:56:28 +0100 (BST)
- cc: <jakub at redhat dot com>, <gcc at gcc dot gnu dot org>
On Sat, 19 May 2001, Mark Mitchell wrote:
> I clipped the wrong ChangeLog hunk. It was this bit:
> else if (require_constant
> && initializer_constant_valid_p (inside_init, TREE_TYPE (inside_init)) == 0)
> pedwarn ("initializer element is not computable at load time");
> That used to be an error.
I think Jakub had best work out how to fix the problem. I think I
understand why this is no longer an error - because non-constant aggregate
initializers of automatic storage duration are allowed in C99, but for C89
with -pedantic they wrongly got a hard error instead of just a warning.
However, I presume Jakub knows what he was doing here (cf
http://gcc.gnu.org/ml/gcc-patches/2000-12/msg00439.html). I don't
properly understand the relevant code; for example, where does the
constructor_constant parameter of digest_init get used apart from as the
same parameter in a nested call to digest_init?
Joseph S. Myers