Closed janedbal closed 2 years ago
Function empty
looks like invalid PHP: https://3v4l.org/sQXtT
I oversimplified the case. It was a class method, which is allowed: https://3v4l.org/er5bV
FunctionHelper
on line 92, so it looks like outdated Slevomat CS. I've checked branches 7.2
and master
. Please try master
.master
now. Please try master
.T_ISSET
and that's wrong.empty
and isset
are probably fixed in PHPCS itself: https://github.com/squizlabs/PHP_CodeSniffer/pull/3610
Yes, the fix is included in the PHPCS 3.7.1 release. Upgrading to that should solve the problem.
Seems like
"slevomat/coding-standard": "dev-master",
"squizlabs/php_codesniffer": "3.7.1",
works fine. Thank you!
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Hi, I assume there will be some official support in upcoming days/weeks, I just want to point out issues I found when analysing our codebase with slevomat/cs 7.2.1 and squizlabs/PHP_CodeSniffer 3.7.0:
SlevomatCodingStandard.Namespaces.ReferenceUsedNamesOnly.ReferenceViaFallbackGlobalName
An error occurred during processing; checking has been aborted. The error message was: Undefined array key "parenthesis_closer" in RequireNullCoalesceOperatorSniff.php:69