------- Comment #2 from dodji at gcc dot gnu dot org 2008-07-31 12:22 -------
Created an attachment (id=15984)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15984&action=view)
candidate partial fix
This patch fixes the problem patially.
if you have:
------------
void
foo ()
{
#define WARNS while(0)
#define DOES_NOT_WARN while(0);
WARNS; // { dg-warning }
DOES_NOT_WARN;
while (0); // { dg-warning }
}
---------------
The compiler (augmented with the patch) says:
/home/dodji/devel/src/gcc-bug-test.cc:6: warning: suggest a space before ; or
explicit braces around empty body in while statement
/home/dodji/devel/src/gcc-bug-test.cc:8: warning: suggest a space before ; or
explicit braces around empty body in while statement
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36478