This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/52467] ICE: canonical types differ for int [0] and int [0]
- From: "daniel.kruegler at googlemail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 03 Mar 2012 14:01:02 +0000
- Subject: [Bug c++/52467] ICE: canonical types differ for int [0] and int [0]
- Auto-submitted: auto-generated
- References: <bug-52467-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52467
Daniel KrÃgler <daniel.kruegler at googlemail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |daniel.kruegler at
| |googlemail dot com
--- Comment #1 from Daniel KrÃgler <daniel.kruegler at googlemail dot com> 2012-03-03 14:01:02 UTC ---
An array of length 0 is not valid. [dcl.array] p1:
"If the constant-expression (5.19) is present, it shall be an integral constant
expression and its value shall be greater than zero."
Thus accepting
int a[0] = {};
or any such variant is a compiler defect.