Skip to content

Conversation

@aschackmull
Copy link
Contributor

Case rules never fall through. This was already handled correctly for rule expressions, but rule statements were missing the implicit break completion. Added qltest and fixed the CFG. I also amended the guards logic a bit to handle default cases in switch expression, which the test also highlighted as missing.

Fixes #14332

@aschackmull aschackmull merged commit efb49fc into github:main Sep 29, 2023
@aschackmull aschackmull deleted the java/switch-rule-stmt-cfg branch September 29, 2023 10:02
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.

Java: SwitchCase expressions should implicitly break rather than fall through

2 participants