public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/55322] New: Suggestion: Warn suspicious usage of arrays of structures
@ 2012-11-14 10:06 stilgarwolf at gmail dot com
  2012-11-14 13:30 ` [Bug c/55322] " mpolacek at gcc dot gnu.org
  2012-11-15 18:24 ` stilgarwolf at gmail dot com
  0 siblings, 2 replies; 3+ messages in thread
From: stilgarwolf at gmail dot com @ 2012-11-14 10:06 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 55322
           Summary: Suggestion: Warn suspicious usage of arrays of
                    structures
    Classification: Unclassified
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: stilgarwolf@gmail.com


struct {
   int x;
   int y;
} array[10];

void xxx() {
   int i=9;

   while(i--) {
      array[i].x = 0;
      array->y = 0;   /* an optional warning for this usage may be helpful */
   }
}


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

end of thread, other threads:[~2012-11-15 18:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-11-14 10:06 [Bug c/55322] New: Suggestion: Warn suspicious usage of arrays of structures stilgarwolf at gmail dot com
2012-11-14 13:30 ` [Bug c/55322] " mpolacek at gcc dot gnu.org
2012-11-15 18:24 ` stilgarwolf at gmail dot com

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).