aik099 / CodingStandard

The PHP_CodeSniffer coding standard I'm using on all of my projects
BSD 3-Clause "New" or "Revised" License
5 stars 2 forks source link

Validate spacing around object operator ("->") #73

Closed aik099 closed 9 years ago

aik099 commented 9 years ago

There is ObjectOperatorSpacing sniff in Squiz standard, but unfortunately it considers object operators indented on different lines as an error. If we change that, then that would be what we need.

$a ->... // error (spacing before)
$a-> ... // error (spacing after)
$a->
... // no error
$a
->// no error