mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-20 03:20:56 +07:00
12 lines
219 B
Java
12 lines
219 B
Java
// "Replace with 'yield'" "true-preview"
|
|
class X {
|
|
int test(String s) {
|
|
return switch (s) {
|
|
case "foo" -> {
|
|
System.out.println("hello");
|
|
yield 123;
|
|
}
|
|
case "bar" -> 2;
|
|
};
|
|
}
|
|
} |