[lworld] RFR: 8247569: [lworld] Align with spec for <vnew> methods [v3]

Mandy Chung mchung at openjdk.org
Wed Oct 19 20:24:29 UTC 2022


On Wed, 19 Oct 2022 10:34:48 GMT, David Simms <dsimms at openjdk.org> wrote:

>> Merged javac and VM work together, includes VM support (JDK-8294224)
>
> David Simms has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Update test/jdk/valhalla/valuetypes/StaticFactoryMethodHandleTest.java
>   
>   Co-authored-by: Mandy Chung <mandy.chung at oracle.com>

Looks good.  A couple more adjustment to the spec.

src/java.base/share/classes/java/lang/invoke/MethodHandleInfo.java line 163:

> 161:     /**
> 162:      * Returns the name of the cracked method handle's underlying member.
> 163:      * This is {@code "<init>"} or {@code "<vnew>"} if the underlying member

Suggestion:

     * This is {@code "<init>"} if the underlying member was a constructor,
     * or {@code "<vnew>"} if the underlying member was a value class static
     * factory method, else it is a simple method name or field name.

src/java.compiler/share/classes/javax/lang/model/element/ExecutableElement.java line 143:

> 141:      * {@return the simple name of a constructor, method, or
> 142:      * initializer}  For a constructor, the name {@code "<init>"} or
> 143:      * {@code "<vnew>"} is returned, for a static initializer, the

Suggestion:

     * initializer} For a constructor, the name {@code "<init>"} is
     * returned, for a value class static factory method, the name 
     * {@code "<vnew>"} is returned, for a static initializer, the

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

Marked as reviewed by mchung (Committer).

PR: https://git.openjdk.org/valhalla/pull/788



More information about the valhalla-dev mailing list