PHP 8.2 | New `PHPCompatibility.Constants.NewConstantsInTraits` sniff by jrfnl · Pull Request #1443 · PHPCompatibility/PHPCompatibility
Navigation Menu
{{ message }}
PHPCompatibility / PHPCompatibility Public
- Notifications You must be signed in to change notification settings
- Fork 204
Conversation
Copy link Copy Markdown
Member
Constants in Traits
It is now possible to define constants in traits.
This adds a new sniff to detect this.
Includes unit tests.
Includes docs.
Refs:
- https://wiki.php.net/rfc/constants_in_traits
- https://www.php.net/manual/en/migration82.new-features.php#migration82.new-features.core.constant-in-traits
- https://www.php.net/manual/en/language.oop5.traits.php#language.oop5.traits.constants
- [RFC] Implement constants in traits php/php-src#8888
Related #1348
> Constants in Traits > > It is now possible to define constants in traits. This adds a new sniff to detect this. Includes unit tests. Includes docs. Refs: * https://wiki.php.net/rfc/constants_in_traits * https://www.php.net/manual/en/migration82.new-features.php#migration82.new-features.core.constant-in-traits * https://www.php.net/manual/en/language.oop5.traits.php#language.oop5.traits.constants * php/php-src#8888
jrfnl
added
Type: enhancement
PR: ready for review
labels
jrfnl
added this to the
10.0.0 milestone
jrfnl
requested a review
from wimg
jrfnl
mentioned this pull request
18 tasks
wimg approved these changes Dec 25, 2022
wimg
merged commit
13e5fb4
into
develop
wimg
deleted the
php-8.2/new-constants-in-traits-sniff
branch
github-actions
bot
removed
the
PR: ready for review
label
jrfnl
mentioned this pull request
jrfnl
added
the
PHP: 8.2
label
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment