void () { doTest("class C {\n" + " private static class Err {\n" + " /*Access can be package-private*/public/**/ boolean notVisible() { return true; }\n" + " }\n"+ " boolean f = new Err(){}.notVisible();\n" + //call on anonymous class! "}"); doTest("class C {\n" + " private static class Err {\n" + " /*Access can be 'private'*/public/**/ static boolean notVisible() { return true; }\n" + " }\n"+ " boolean f = new Err(){}.notVisible();\n" + //call on anonymous class! "}"); }