This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/12807] [tree-ssa] ICE on variable sized array in class
- From: "falk dot hueffner at student dot uni-tuebingen dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Oct 2003 10:58:40 -0000
- Subject: [Bug c++/12807] [tree-ssa] ICE on variable sized array in class
- References: <20031028100505.12807.reichelt@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12807
------- Additional Comments From falk dot hueffner at student dot uni-tuebingen dot de 2003-10-28 10:58 -------
Subject: Re: [tree-ssa] ICE on variable sized array in class
"reichelt at igpm dot rwth-aachen dot de" <gcc-bugzilla@gcc.gnu.org> writes:
> Well, I think it's an instance of the variable sized array
> extension.
Hm, could you point me to the documentation for that?
> You just have a pointer there, as far as I understand it. The memory
> is allocated in a different location at runtime. So there should be
> no problem to compute sizeof().
>
> Btw, all versions since 3.0 accept the code - and since 3.3.1 they
> reject it if -pedantic is specified.
But not this:
struct A
{
static int n;
char text[n];
};
So it's probably rather a bug in 3.3.