PSR-12 states that
All binary and ternary (but not unary) operators MUST be preceded and followed by at least one space
Sometimes I find it useful to write arithmetic operators without surrounding whitespace, since it can help make the meaning clear at a glance.
Consider this very simple example:
$foo = 1 + 2*3 + 4 - 5/7; // Syntax indicates the order in which the operations are performed.
$bar = 1 + 2 * 3 + 4 - 5 / 7; // Syntax does not indicate anything.
What are the reasons for requiring surrounding whitespace for (arithmetic) operators?
Magnar :)