Bodyless loop (was: Comparing strings...)
Henry Spencer
henry at zoo.toronto.edu
Sat Oct 20 01:50:17 AEST 1990
In article <18573 at haddock.ima.isc.com> karl at ima.isc.com (Karl Heuer) writes:
>>By the way, tacking the ";" on the end of the while is a great way to
>>trip up your readers...
>
>This is a valid concern. On the other hand, there are those of us who gag at
>the sight of a naked semicolon on a line by itself, which is what I guess
>Henry to be suggesting as an alternative.
Actually, no, my preferred alternative is
while (...)
continue;
although I can live with minor variants like using {} instead of continue.
(This is, incidentally, just about the only use of continue that I'm happy
with!)
--
The type syntax for C is essentially | Henry Spencer at U of Toronto Zoology
unparsable. --Rob Pike | henry at zoo.toronto.edu utzoo!henry
More information about the Comp.lang.c
mailing list