This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PR java/19870 (Part 2/2): Handle private static methods accessed across nested classes


>>>>> "Ranjit" == Ranjit Mathew <rmathew@gmail.com> writes:

>> If m() were not private, the call would be to Sub.m(), which would be
>> invalid because it would be a use of 'this' in a static context.

Ranjit> What static context?

In a super() or this() call the arguments are considered to be in a
static context.  The idea is that before the other constructor is
called, accesses via 'this' or 'super' are invalid.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]