Different behaviors of Ref_InvokeSpecial

- liangchenblue at gmail.com
Mon Oct 4 12:38:06 UTC 2021


Hello,
Bystander here. This comment in code [1] may be related information.

The question here is more like how the access to methods should be
changed. In prior versions, if you want to expose a private method to
be overridable, you have to change all calls to it from invokespecial
to invokevirtual, and it's no surprise if you need extra housekeeping
around simple access changes. But let's take a step back, why are we
changing the access of these methods at all, and how are they
necessary?

Sending this to jdk-dev as this is related to jdk itself than valhalla.

Best regards

[1] https://github.com/openjdk/jdk/blob/0828273b898cca5368344e75f1c3f4c3a29dde80/src/java.base/share/classes/java/lang/invoke/AbstractValidatingLambdaMetafactory.java#L157


More information about the jdk-dev mailing list