// "Lift 'throw' out of 'switch' expression" "true-preview" class Foo { int bar() { throw switch (7) { default -> { if (true) { yield new RuntimeException("then"); } else { yield new RuntimeException("else"); } } }; } }