[comp.lang.c] Another issue in the = and == war

gwyn@brl-smoke.ARPA (Doug Gwyn ) (01/13/88)

In article <1168@ark.cs.vu.nl>, maart@cs.vu.nl (Maarten Litmaath) writes:
> So, why is the priority of `=' chosen to be less than the priority of
> `==' (in this case `!=') ?

Some of the precedence choices for C (p.49 of K&R) are admittedly poor,
mostly those involving bitwise and shift operators.  They can't be
changed at this point; too much correctly-written code would be invalidated.

I fairly often write things like
	bool	done;
	/* ... */
	done = nextp == NULL;
In general, it is good for assignment to have very low precedence.