This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/39012] New: GCC accepts badly formatted while statement
- From: "gp dot bolton at computer dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Jan 2009 21:02:43 -0000
- Subject: [Bug c/39012] New: GCC accepts badly formatted while statement
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
while loop is badly formatted in the following example. Although an "obvious"
bug, this type of thing can occur when modifying existing code having do-while
statements and converting them to while statements.
bool f()
{
return true;
}
void g()
{
bool b( false );
while ( !b )
{
b = f();
} while ( !b );
}
--
Summary: GCC accepts badly formatted while statement
Product: gcc
Version: 4.3.2
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: gp dot bolton at computer dot org
GCC build triplet: i386-apple-darwin9.6.0
GCC host triplet: i386-apple-darwin9.6.0
GCC target triplet: i386-apple-darwin9.6.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39012