Skip to content

Commit fd058e6

Browse files
committed
Composer/ruleset: allow for PHP 8.1 token constants
PHP 8.1 will introduce yet more new token constants. Detection for `T_READONLY` is already in PHPCompatibility 10.0, `T_ENUM` will follow shortly. As PHPCS polyfills these tokens, we should allow for these to be used in external PHPCS standards. The token constants are expected to be backfilled by PHPCS as of version 3.7.0.
1 parent 263987e commit fd058e6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

PHPCSDev/ruleset.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@
2929
<exclude name="PHPCompatibility.Constants.NewConstants.t_name_fully_qualifiedFound"/>
3030
<exclude name="PHPCompatibility.Constants.NewConstants.t_name_qualifiedFound"/>
3131
<exclude name="PHPCompatibility.Constants.NewConstants.t_name_relativeFound"/>
32+
<exclude name="PHPCompatibility.Constants.NewConstants.t_readonlyFound"/>
33+
<exclude name="PHPCompatibility.Constants.NewConstants.t_enumFound"/>
3234
<exclude name="PHPCompatibility.Constants.RemovedConstants.t_bad_characterFound"/>
3335
</rule>
3436

0 commit comments

Comments
 (0)