langtools/test/tools/javac/Parens2.java
author duke
Wed, 05 Jul 2017 23:01:50 +0200
changeset 44228 e46434c65a2b
parent 26662 7cf828d7c8fc
permissions -rw-r--r--
Merge

/*
 * @test /nodynamiccopyright/
 * @bug 4408036
 * @summary Compiler accepted "(i=2);" as a valid expession statement.
 * @author gafter
 *
 * @compile/fail/ref=Parens2.out -XDrawDiagnostics Parens2.java
 */

class Parens2 {
    void f() {
        int i;
        (i = 2);
    }
}