Files
openide/java/java-tests/testData/refactoring/extractMethodAndDuplicatesInplace/YieldWithDuplicate.java
Alexandr Suhinin 27a128ba6b IDEA-275529 extract method: support yield statement
GitOrigin-RevId: 7b277cc420b34693ad3791e80c128328ef671fe2
2021-08-18 09:51:50 +00:00

15 lines
336 B
Java

public class Test {
String test(String s){
return switch (s) {
case "a" -> {
<selection>System.out.println();
yield "one";</selection>
}
case "b" -> {
System.out.println();
yield "two";
}
default -> "three";
};
}
}