< prev index next >
test/langtools/tools/javac/diags/examples/ReturnOutsideSwitchExpression.java
Print this page
*** 22,32 ****
*/
// key: compiler.err.return.outside.switch.expression
// key: compiler.note.preview.filename
// key: compiler.note.preview.recompile
! // options: --enable-preview -source 12
class ReturnOutsideSwitchExpression {
int t(int i) {
return switch (i) {
default: return -1;
--- 22,32 ----
*/
// key: compiler.err.return.outside.switch.expression
// key: compiler.note.preview.filename
// key: compiler.note.preview.recompile
! // options: --enable-preview -source 13
class ReturnOutsideSwitchExpression {
int t(int i) {
return switch (i) {
default: return -1;
< prev index next >