RFR(S+M) / 8022701 Accessibility checking: InvocationTargetException is thrown instead of IllegalAccessError

David Chase david.r.chase at oracle.com
Fri Sep 6 23:59:01 UTC 2013


new, improved webrev: http://cr.openjdk.java.net/~drchase/8022701/webrev.02/
Same small changes to the sources, plus a test.

bug: wrong exception was thrown in call of methodhandle to private method

fix: detect special case of IllegalAccessException, convert to IllegalAccessError

testing:
verified that the test would pass with modified library
verified that the test would fail with old library
verified that the test would fail if the class substitution (for some reason) did not occur
jtreg of jdk/test/java/lang/invoke -- note that the new exception thrown is a subtype of the old one, so this is unlikely to create a new surprise




More information about the core-libs-dev mailing list