marc-mabe/php-enum-phpstan

Enum class reflection extension for PHPStan

Maintainers

👁 marc-mabe

Package info

github.com/marc-mabe/php-enum-phpstan

Type:phpstan-extension

pkg:composer/marc-mabe/php-enum-phpstan

Statistics

Installs: 881 330

Dependents: 5

Suggesters: 0

Stars: 13

Open Issues: 0

v3.0.0 2024-12-10 08:20 UTC

Requires

Requires (Dev)

Suggests

None

Provides

None

Conflicts

None

Replaces

None

BSD-3-Clause 9c39239c76cc4dfb8cd33463253568c23c208276

enumPHPStan

This package is auto-updated.

Last update: 2026-05-23 17:39:11 UTC


README

👁 License
👁 Latest Stable

PHP-Enum enumerations with native PHP.

PHPStan is a static code analysis tool.

PHPStan focuses on finding errors in your code without actually running it. It catches whole classes of bugs even before you write tests for the code. It moves PHP closer to compiled languages in the sense that the correctness of each line of the code can be checked before you run the actual line.

This PHPStan extension makes enumerator accessor methods and enum possible values known to PHPStan.

Install

Install via Composer

composer require --dev marc-mabe/php-enum-phpstan

and include extension.neon in your project's PHPStan config

includes:
 - vendor/marc-mabe/php-enum-phpstan/extension.neon