Tue, 10 Apr 2012 08:15:25 -0700
7074397: Build infrastructure changes (makefile re-write)
Summary: New makefiles transition, old and new living side by side for now.
Reviewed-by: ohair, jjg, dholmes, ohrstrom, erikj, ihse, tgranat, ykantser
Contributed-by: ohrstrom <fredrik.ohrstrom@oracle.com>, erikj <erik.joelsson@oracle.com>, ihse <magnus.ihse.bursie@oracle.com>, tgranat <torbjorn.granat@oracle.com>, ykantser <yekaterina.kantserova@oracle.com>
duke@1 | 1 | /* |
duke@1 | 2 | * @test /nodynamiccopyright/ |
duke@1 | 3 | * @bug 5003235 |
duke@1 | 4 | * @summary Accessibility of private inner class |
duke@1 | 5 | * @author Peter von der Ah\u00e9 |
jjg@611 | 6 | * @compile/fail/ref=T5003235b.out -XDdiags=%b:%l:%_%m T5003235b.java |
duke@1 | 7 | */ |
duke@1 | 8 | |
duke@1 | 9 | class Outer { |
duke@1 | 10 | public Inner inner; |
duke@1 | 11 | |
duke@1 | 12 | public void create() { |
duke@1 | 13 | inner = new Inner(); |
duke@1 | 14 | } |
duke@1 | 15 | |
duke@1 | 16 | private class Inner { |
duke@1 | 17 | int k = 100; |
duke@1 | 18 | protected int l = 100; |
duke@1 | 19 | public int m = 100; |
duke@1 | 20 | protected int n = 100; |
duke@1 | 21 | } |
duke@1 | 22 | } |
duke@1 | 23 | |
duke@1 | 24 | class Access { |
duke@1 | 25 | public static void main(String[] args) { |
duke@1 | 26 | Outer outer = new Outer(); |
duke@1 | 27 | outer.create(); |
duke@1 | 28 | System.out.println("Value of k: " + outer.inner.k); |
duke@1 | 29 | System.out.println("Value of l: " + outer.inner.l); |
duke@1 | 30 | System.out.println("Value of m: " + outer.inner.m); |
duke@1 | 31 | System.out.println("Value of n: " + outer.inner.n); |
duke@1 | 32 | } |
duke@1 | 33 | } |