------- Comment #2 from paolo dot carlini at oracle dot com 2008-07-17 10:06 ------- (In reply to comment #0) > int bit; > for( bit = 1; bit; bit *= 2 )
This is pretty straightforward, isn't it? At some point bit - a *signed* integral type - overflows and this leads to undefined bahavior. -- paolo dot carlini at oracle dot com changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED Resolution| |INVALID http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36862