antlr/antlr-php-runtime-phpstan

ANTLR4 PHP 运行时扩展用于 PHPStan。

0.3.0 2021-11-20 16:02 UTC

This package is auto-updated.

Last update: 2024-09-20 22:08:00 UTC


README

Travis CI Latest Stable Version License

ANTLR4 PHP 运行时 进行静态分析。

特性

此扩展为上下文子规则获取器提供正确的返回类型。

安装

使用 Composer

composer require --dev antlr/antlr-php-runtime-phpstan

注册插件

如果你还安装了 phpstan/extension-installer,那么你已经设置好了!

手动安装

如果你不想使用 phpstan/extension-installer,请将 extension.neon 包含在你的项目 PHPStan 配置中

includes:
    - vendor/antlr/antlr-php-runtime-phpstan/extension.neon

测试

要运行所有单元测试,请使用本地安装的 PHPUnit

./vendor/bin/phpunit