public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/11943] New: Accepts invalid declaration "int x[2, 3];" in C99 mode
@ 2003-08-16  8:25 falk at debian dot org
  2003-08-16  9:04 ` [Bug c/11943] " debian-gcc at lists dot debian dot org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: falk at debian dot org @ 2003-08-16  8:25 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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

           Summary: Accepts invalid declaration "int x[2, 3];" in C99 mode
           Product: gcc
           Version: 3.3.1
            Status: UNCONFIRMED
          Keywords: accepts-invalid
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: falk at debian dot org
                CC: gcc-bugs at gcc dot gnu dot org

In C99, the brackets must contain an assignment-expression, however, "2, 3" is
not an assignment-expression. I don't have the C89 standard, but I guess it's
similar.

It would be nice to reject this code, because it's a totally useless language
extension, and it might confuse newbies trying to declare two-dimensional arrays.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2003-10-24 16:11 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-16  8:25 [Bug c/11943] New: Accepts invalid declaration "int x[2, 3];" in C99 mode falk at debian dot org
2003-08-16  9:04 ` [Bug c/11943] " debian-gcc at lists dot debian dot org
2003-08-16 13:19 ` pinskia at gcc dot gnu dot org
2003-08-23  1:19 ` dhazeghi at yahoo dot com
2003-10-24 15:39 ` cvs-commit at gcc dot gnu dot org
2003-10-24 16:12 ` pinskia at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).