QualifiedAccess_3.java revision 0
0N/A * @test /nodynamiccopyright/ 0N/A * @bug 4094658 4785453 0N/A * @summary Test enforcement of JLS 6.6.1 and 6.6.2 rules requiring that 0N/A * the type to which a component member belongs be accessible in qualified 0N/A * @run shell QualifiedAccess_3.sh 0N/A // These are all OK. 0N/A // These are NOT errors, and should NOT be detected, as observed. 0N/A /*------------------------------------* 0N/A Baz.Quux.Quem y = null; 0N/A *------------------------------------*/ 0N/A int i =
p1.a.
length;
// ERROR - Type of 'a' not accessible 0N/A // The type of the expression from which a component 0N/A // is selected must be accessible.