Jan Lahoda c2d9172419 8169197: Improve error reporting for compiling against unexported package
When a type cannot be found, look into other modules, search for possible viable types, and report them conveniently to the user.

Reviewed-by: mcimadamore, jjg
2017-01-11 10:59:57 +01:00

27 lines
557 B
Java

/*
* @test /nodynamiccopyright/
* @bug 5003235
* @summary Private inner class accessible from subclasses
* @author Peter von der Ah\u00e9
* @compile/fail/ref=T5003235a.out -XDrawDiagnostics T5003235a.java
*/
class Super {
Inner i;
private class Inner {
void defaultM() {}
protected void protectedM() {}
public void publicM() {}
private void privateM() {}
}
}
class Sub extends Super {
void foo() {
i.defaultM();
i.protectedM();
i.publicM();
i.privateM();
}
}