1 /** 2 * @test /nodynamiccopyright/ 3 * @bug 8206986 4 * @compile/fail/ref=SwitchStatementBroken.out -XDrawDiagnostics --enable-preview -source 12 SwitchStatementBroken.java 5 */ 6 7 public class SwitchStatementBroken { 8 9 private void statementBroken(int i) { 10 String res; 11 12 switch (i) { 13 case 0 -> { res = "NULL-A"; } 14 case 1: { res = "NULL-A"; break; } 15 } 16 } 17 18 }