And I think he's agreeing with you, he's just sarcastic.
C does not support his first example. The standard states that the behavior is undefined.
You're probably not wrong, but I specifically remember there was something you could do in order to trick the compiler to allow modification on the left hand side to happen. It could possibly be by having two variable names referencing the same variable - for example.
Besides, the whole point was that it's usually not clever "trying to be clever". It just creates confusion. I don't personally believe the majority of people need to test the entire C spec to it's absolute boundary. A subset serves most people perfectly well.
That's stylistically ugly but not hard to predict; at some point I had it beaten into my head that ternaries are always at the bottom of the single-character operator precedence stack (I really hope all languages stick to that). I'd expect most people to know this.
> z = a & b > c | d
That is harder to predict. I wouldn't expect most people to know this one without looking up a precedence list.
Also there is none of the code golf in there that you have just given as an example.
If I remember rightly, there is the example:
Depending on the language (and sometimes even if you have optimizations set for those that compile to binaries), you'll get a different answer.I always love (read sarcasm) to see awesome code, such as:
or: And then of course, the statement: "my code doesn't need comments because the code comments itself"...