For vs while (was Re: Comparing strings...)

Henry Spencer henry at zoo.toronto.edu
Tue Oct 23 02:34:04 AEST 1990


In article <8308 at scolex.sco.COM> seanf (Sean Fagan) writes:
>#define	while(cond)	for(;cond;)
>
>(I've wondered why C had while, because of this.  The only think I could
>think of was that for came after while, and They didn't want to break
>existing code...  Any commentators?  [Henry?  Chris?  Doug?  Dennis?])

Do bear in mind that the whole preprocessor was an afterthought, and did
not exist in the original implementation.
-- 
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