PHP_CodeSniffer
PHP_CodeSniffer copied to clipboard
Checking the conversion of some expressions to combined assignments
The PHP programming language supports also the usage of combined operators. :thought_balloon: I propose to search for places where variable names can be replaced by combined assignments. How do you think about to offer corresponding source code analyses and transformations? :thinking:
While none of the standards included with PHPCS contains such a sniff, you may be interested to hear that the external Slevomat standard does: SlevomatCodingStandard.Operators.RequireCombinedAssignmentOperator