< prev index next >

test/langtools/tools/javac/switchexpr/DefiniteAssignment1.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. --- 1,7 ---- /* ! * Copyright (c) 2018, 2019, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
*** 23,33 **** /** * @test * @bug 8214031 * @summary Verify that definite assignment when true works (legal code) ! * @compile --enable-preview --source 13 DefiniteAssignment1.java * @run main/othervm --enable-preview DefiniteAssignment1 */ public class DefiniteAssignment1 { public static void main(String[] args) { int a = 0; --- 23,33 ---- /** * @test * @bug 8214031 * @summary Verify that definite assignment when true works (legal code) ! * @compile --enable-preview --source ${jdk.version} DefiniteAssignment1.java * @run main/othervm --enable-preview DefiniteAssignment1 */ public class DefiniteAssignment1 { public static void main(String[] args) { int a = 0;
< prev index next >