Symfony-coding-standard
Symfony-coding-standard copied to clipboard
Symfony.ControlStructure.YodaConditions.Invalid not working with static class variables
Code like the following breaks the sniff, reporting an error either way:
if (foo::$bar === bar::$foo) {
}
As a workaroung, I'm using https://github.com/slevomat/coding-standard#slevomatcodingstandardcontrolstructuresdisallowyodacomparisonrequireyodacomparison- which can handle this and also brings an auto-fixer.
GH-183 would implicitly fix this.