This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/26581] incomplete (unsized) static array types cannot be completed



------- Comment #3 from joseph at codesourcery dot com  2006-03-06 14:10 -------
Subject: Re:   New: incomplete (unsized) static array types
 cannot be completed

On Mon, 6 Mar 2006, bernard at brenda-arkle dot demon dot co dot uk wrote:

> static int thingy2[];
> static int thingy2[1];

This contradicts 6.9.2 paragraph 3: "If the declaration of an identifier 
for an object is a tentative definition and has internal linkage, the 
declared type shall not be an incomplete type.".  (Undefined behavior 
since it's not in a Constraints section, so diagnostic not required, but 
as a quality of implementation matter it should be diagnosed at least with 
-pedantic.)


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26581


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]