Abstract
This paper illustrates how to check access to protected members in the JVM, which is not explained in [7] and, to the author’s knowledge, has been completely neglected in the research literature. This aspect of enforcing type safety in the JVM is rather subtle and its correct implementation is not straightforward, as also evidenced by a bug in Sun’s Java 2 SDK version 1.4 that causes some illegal programs to be accepted and some legal programs to be rejected (see [3] for concrete examples with source code). Java compilers can easily check access to protected members and constructors by looking them up in their declaring classes, which must be available in source or bytecode form. Checking access to protected members in the JVM is made difficult by dynamic class loading.
Talk to us
Join us for a 30 min session where you can share your feedback and ask us any queries you have
Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.