RFR: 8187655: jdk.lambda.vm.InterfaceAccessFlagsTest.testPrivateMethodCall needs update after nestmates support [v2]

Chen Liang liach at openjdk.org
Wed Nov 8 00:34:02 UTC 2023


On Tue, 7 Nov 2023 19:10:18 GMT, ExE Boss <duke at openjdk.org> wrote:

>> Mandy Chung has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Simplify the transformation code and easier to read
>
> test/jdk/jdk/lambda/separate/ClassToInterfaceConverter.java line 53:
> 
>> 51:         
>> 52:         return Classfile.of().transform(classModel,
>> 53:             ClassTransform.dropping(ce -> ce instanceof MethodModel mm && mm.methodName().stringValue().equals("<init>"))
> 
> `Utf8Entry::equalsString(…)` might be more efficient:
> Suggestion:
> 
>             ClassTransform.dropping(ce -> ce instanceof MethodModel mm && mm.methodName().equalsString("<init>"))

Also can use `ConstantDescs.INIT_NAME` to indicate class initializers

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/16526#discussion_r1385795131


More information about the core-libs-dev mailing list