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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

checker: require else branch in [flag] enum match #19375

Merged
merged 1 commit into from
Sep 18, 2023

Conversation

Delta456
Copy link
Member

@Delta456 Delta456 commented Sep 17, 2023

Closes #19181

馃 Generated by Copilot at d353687

Enforce else branch for match statements on flag enums. Add a checker condition, a test case, and a test output file for this rule.

馃 Generated by Copilot at d353687

  • Enforce else branch for match statements on flag enums (link)
  • Add a test case and output for the checker error (link, link)

@Delta456 Delta456 marked this pull request as draft September 17, 2023 20:52
@Delta456 Delta456 marked this pull request as ready for review September 18, 2023 07:51
@spytheman spytheman merged commit be53b02 into vlang:master Sep 18, 2023
48 checks passed
@Delta456 Delta456 deleted the flag_enum_exhaustive_else_branch branch September 18, 2023 13:23
Wertzui123 pushed a commit to Wertzui123/v that referenced this pull request Oct 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[flag] enums exhaustive match is missing
2 participants