From: KarlNyberg on 22 Mar 2010 12:55 Yeah, I had one of these drive me bonkers for a while: for (i = 0; i < something; i++); { /* something here */ } Always executed ONCE... Even when it wasn't supposed to! :-(
From: Gautier write-only on 22 Mar 2010 13:07 On 22 Mrz., 17:55, KarlNyberg: > Yeah, I had one of these drive me bonkers for a while: > > for (i = 0; i < something; i++); > { > /* something here */ > } > > Always executed ONCE... Even when it wasn't supposed to! :-( That's more a typical C annoyance (there was a funny list about that). Should not come from typing Ada code (not ';' after for ... loop) G.
From: Gautier write-only on 24 Mar 2010 17:48 > On 22 Mrz., 17:55, KarlNyberg: > > > Yeah, I had one of these drive me bonkers for a while: > > > for (i = 0; i < something; i++); > > { > > /* something here */ > > } > > > Always executed ONCE... Even when it wasn't supposed to! :-( > > That's more a typical C annoyance (there was a funny list about that). A nice of such lists: "The Top 10 Ways to get screwed by the "C" programming language" http://www.andromeda.com/people/ddyer/topten.html Your "';' before {}" belongs to the #8 one...
First
|
Prev
|
Pages: 1 2 Prev: ANN: Player3_Ada binding Next: Copying rows in a two dimensional array. |