mirror of
https://github.com/danog/psalm.git
synced 2024-11-27 04:45:20 +01:00
ed2cde1b93
This will highlight unused code. Ref: https://github.com/php/php-src/pull/5412 Ref: https://wiki.php.net/rfc/make-reflection-setaccessible-no-op Ref: https://github.com/php/php-src/pull/5411 Example https://3v4l.org/PNeeZ ```php <?php class Foo { private $bar = 'baz'; private function taz() { return 'waz'; } } //var_dump((new ReflectionProperty(Foo::class, 'bar'))->getValue(new Foo)); //var_dump((new ReflectionMethod(Foo::class, 'taz'))->invoke(new Foo)); ``` Produces (starting from PHP 8.1): ``` string(3) "baz" string(3) "waz" ``` |
||
---|---|---|
.circleci | ||
.github | ||
assets/psalm-phar | ||
bin | ||
build/phpunit | ||
dictionaries | ||
docs | ||
examples | ||
src/Psalm | ||
stubs | ||
tests | ||
vendor-bin | ||
.appveyor.yml | ||
.editorconfig | ||
.gitattributes | ||
.gitignore | ||
box.json.dist | ||
CODE_OF_CONDUCT.md | ||
composer.json | ||
config.xsd | ||
CONTRIBUTING.md | ||
keys.asc.gpg | ||
LICENSE | ||
phpcs.xml | ||
phpunit.xml.dist | ||
psalm | ||
psalm-baseline.xml | ||
psalm-language-server | ||
psalm-plugin | ||
psalm-refactor | ||
psalm.xml.dist | ||
PsalmLogo.png | ||
psalter | ||
README.md | ||
scoper.inc.php | ||
UPGRADING.md |
Psalm
Psalm is a static analysis tool for finding errors in PHP applications.
Installation
To get started, check out the installation guide.
Live Demo
You can play around with Psalm on its website.
Documentation
Documentation is available on Psalm’s website, generated from the docs folder.
Interested in contributing?
Have a look at CONTRIBUTING.md.
Who made this
Built by Matt Brown (@muglug).
Maintained by Orklah (@orklah), Daniil Gentili (@danog), and Bruce Weirdan (@weirdan).
The engineering team at Vimeo have provided a lot encouragement, especially @nbeliard, @erunion and @nickyr.