Re: while (1) vs. for ( ;; )



Keith Thompson wrote:
Keith Thompson <kst-u@xxxxxxx> writes:
[...]

In another thread, I've railed against "if (0 = a)", even though it's
semantically identical to "if (a == 0)".  And yes, I'm taking the
opposite side of this argument.  The difference, which is largely in
my head, is that I don't find either "while (1)" or "for (;;)" to be
ugly or jarring.


Of course, I meant "if (0 == a)", not "if (0 = a)".

Gloating over the irony of that typo is left as an exercise for the
reader.

That's OK (unless you have argued in favor of the design choice of using `=' for assignment in C ;-)


August
.



Relevant Pages