Files
Tagir Valeev 2b2d79fb6a [java-intentions] ConvertSwitchToIfIntention: fix brace handling
Fixes EA-795482 - IOE: JavaParserUtil.parseFragment

GitOrigin-RevId: 63fe89da84e4432fab8f8f191c139add97553640
2023-02-13 14:37:08 +00:00

12 lines
243 B
Java

// "Replace 'switch' with 'if'" "true-preview"
class X {
void test(int x) {
if (x == 1) {
{
System.out.println("hello");
}
} else if (x == 2) {
System.out.println("oops");
}
}
}