RFR: JDK-8315458 Implement JEP 463: Implicitly Declared Classes and Instance Main Method (Second Preview) [v30]
Alan Bateman
alanb at openjdk.org
Tue Nov 21 15:37:31 UTC 2023
On Mon, 20 Nov 2023 20:45:22 GMT, Jim Laskey <jlaskey at openjdk.org> wrote:
>> Address changes from JEP 445 to JEP 463.
>>
>> - Move from a SYNTHETIC unnamed class to a MANDATED implicit class.
>>
>> - Don't mark class on read.
>>
>> - Remove reflection and annotation processing related to unnamed classes.
>>
>> - Simplify main method search.
>
> Jim Laskey has updated the pull request incrementally with one additional commit since the last revision:
>
> Update test
src/java.base/share/classes/java/lang/Class.java line 4847:
> 4845: @PreviewFeature(feature=PreviewFeature.Feature.IMPLICIT_CLASSES)
> 4846: @CallerSensitive
> 4847: public Method findMainMethod() {
Renaming it to findMainMethod separates it from the existing getXXXMethod methods (good) but it makes it more obvious that this is a method for launchers. I'm not 100% sure that java.lang.Class is the right place for this, it feels out of place.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16461#discussion_r1400785014
More information about the compiler-dev
mailing list