Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bunch of enum issues #6280

Merged
merged 1 commit into from Feb 16, 2022
Merged

Fix bunch of enum issues #6280

merged 1 commit into from Feb 16, 2022

Conversation

SpacePossum
Copy link
Contributor

resolves the issue described in this comment
#6204 (comment)

@SpacePossum SpacePossum added kind/bug topic/PHP8.1 Related to features available in PHP 8.1+ labels Feb 9, 2022
@coveralls
Copy link

coveralls commented Feb 9, 2022

Coverage Status

Coverage decreased (-0.005%) to 93.172% when pulling 37ef9af on SpacePossum:master_CommentsAnalyzer_enum_support into c753f74 on FriendsOfPHP:master.

@SpacePossum SpacePossum changed the title CommentsAnalyzer - enum is a structural element Fix bunch of enum issus Feb 10, 2022
src/Tokenizer/Token.php Outdated Show resolved Hide resolved
@SpacePossum SpacePossum marked this pull request as draft February 10, 2022 15:30
@SpacePossum
Copy link
Contributor Author

SpacePossum commented Feb 10, 2022

Inheritance is not supported. Enums may not extend or be extended.

however we are allowed to make the methods final .. so wondering what to do with the NoUnneededFinalMethodFixer
https://3v4l.org/hUYen#v8.1.2

PHP also allows for protected methods on enums ..hmm...

@SpacePossum SpacePossum marked this pull request as ready for review February 16, 2022 14:15
@SpacePossum SpacePossum merged commit ad4a709 into PHP-CS-Fixer:master Feb 16, 2022
@SpacePossum SpacePossum deleted the master_CommentsAnalyzer_enum_support branch February 16, 2022 14:36
@SpacePossum SpacePossum changed the title Fix bunch of enum issus Fix bunch of enum issues Mar 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug topic/PHP8.1 Related to features available in PHP 8.1+
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants