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

Add PHPStan rule to detect duplicate enum values #343

Merged
merged 3 commits into from
Nov 15, 2023
Merged

Conversation

spawnia
Copy link
Collaborator

@spawnia spawnia commented Nov 15, 2023

  • Added or updated tests
  • Added or updated the README.md
  • Detailed changes in the CHANGELOG.md unreleased section

Related Issue/Intent

Duplicate enum values lead to runtime errors, e.g. getInstances().

Changes

Adds a PHPStan rule that detects duplicate enum values.

Breaking changes

None.

@spawnia spawnia marked this pull request as ready for review November 15, 2023 15:38
@spawnia spawnia merged commit b4320ac into master Nov 15, 2023
4 of 8 checks passed
@spawnia spawnia deleted the unique-values-rule branch November 15, 2023 15:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant