Duplicate :
|
###@###.### reports: $ cat -n Super.java ; cat -n Sub.java 1 class Super { 2 Inner i; 3 private class Inner { 4 void bar() {} 5 } 6 } 1 class Sub extends Super { 2 void foo() { i.bar(); } 3 } $ javac Super.java Sub.java No error reported, which seems to violate JLS 6.6.1 (i.bar() should not be accessible). ###@###.### 2004-11-10 04:27:36 GMT
|