It's not an edge case. It's consistent with all `OP=` operators.
The reason is simple: You can't evaluate an expression as a boolean and as a list.
| [reply] |
> It's consistent with all `OP=` operators.
You are missing the point, this sub-thread is talking about x not x=
How many operators do you know which depend on the LHS being in brackets or not?
| [reply] [d/l] [select] |
Ah, ok.
I know three cases where parens matter (aside from when they override precedence or disambiguate syntax):
- (...) = ... vs ... = ...
- (...) x ... vs ... x ...
- eof vs eof()
I think there's another one.
For the first two, it was either that or create a new operator. No other operators behave differently based on whether one their operand is list-like or not. It's a pity = and x didn't adopt the same definition of list-like, but then again, one expects lvalues and the other expects rvalues.
| [reply] [d/l] [select] |