DirectMethodHandleDesc for MethodHandles.classData/classDataAt
-
liangchenblue at gmail.com
Fri Mar 10 00:10:46 UTC 2023
Hello,
I request the addition of 2 common DirectMethodHandleDesc constants,
for the bootstrap methods MethodHandles::classData and
MethodHandles::classDataAt, in ConstantDescs.
Since class data is almost exclusively accessed by generated bytecode
only, having their condy bootstrap method available would be
convenient to users when the Classfile API is publicly available. For
instance, in JDK, there are already 2 places
(InnerClassLambdaMetafactory, BindingSpecializer) where classData is
used as a bootstrap method for condys, and they will be migrating to
Classfile API soon.
Is this proposal feasible? If yes, I am more than glad to submit a
changeset adding these 2 constants.
Chen Liang
More information about the core-libs-dev
mailing list