swissspidy / phpstan-no-private
PHPStan rules for detecting usage of pseudo-private functions, classes, and methods.
Installs: 42 786
Dependents: 19
Suggesters: 2
Security: 0
Stars: 8
Watchers: 3
Forks: 1
Open Issues: 1
Type:phpstan-extension
Requires
- php: ^7.4 || ^8.0
- phpstan/phpstan: ^2.0
Requires (Dev)
- dealerdirect/phpcodesniffer-composer-installer: ^1.0.0
- nikic/php-parser: ^v5.3.1
- php-parallel-lint/php-parallel-lint: ^1.4
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-strict-rules: ^2.0
- phpunit/phpunit: ^9.5
- slevomat/coding-standard: ^8.8.0
- squizlabs/php_codesniffer: ^3.5.3
README
This PHPStan extension emits deprecation warnings on code which uses properties/functions/methods/classes which are annotated as @access private
.
Installation
To use this extension, require it in Composer:
composer require --dev swissspidy/phpstan-no-private
If you also install phpstan/extension-installer then you're all set!
Manual installation
If you don't want to use phpstan/extension-installer
, include rules.neon in your project's PHPStan config:
includes: - vendor/swissspidy/phpstan-no-private/rules.neon
Credits
This project is a fork of the excellent phpstan/phpstan-deprecation-rules, which provides rules that detect usage of deprecated classes, methods, properties, constants and traits.