squizlabs / PHP_CodeSniffer

PHP_CodeSniffer tokenizes PHP files and detects violations of a defined set of coding standards.
BSD 3-Clause "New" or "Revised" License
10.67k stars 1.48k forks source link

Generic/LowerCaseType: examine types in arrow function declarations #3660

Closed jrfnl closed 2 years ago

jrfnl commented 2 years ago

PHP 7.4 arrow functions were not yet being taken into account for this sniff.

Fixed now. Includes unit tests.

gsherwood commented 2 years ago

Thanks for adding this