[foreign-memaccess+abi] RFR: 8310362: Improve composability of handle derived from layouts

Maurizio Cimadamore mcimadamore at openjdk.org
Thu Jun 22 18:18:20 UTC 2023


On Thu, 22 Jun 2023 17:54:41 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:

>> src/java.base/share/classes/java/lang/foreign/MemoryLayout.java line 240:
>> 
>>> 238:  * The var handles returned by {@link #varHandle(PathElement...)} and {@link ValueLayout#varHandle()} feature certain
>>> 239:  * <i>access mode restrictions</i>. A var handle is associated with an access size {@code S}, derived from the
>>> 240:  * {@linkplain ValueLayout#byteSize() byte size} of this layout, and an alignment constraint {@code B}, derived from the
>> 
>> `of this layout` looks weird for a toplevel javadoc section (here and elsewhere)
>
> What should I say here? Is just "of the layout" better? Or should it be more elaborate, like "of the receiver layout", or "of the layout on which this method is invoked"

"of the receiver layout" seems more correct, even if more verbose.

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

PR Review Comment: https://git.openjdk.org/panama-foreign/pull/840#discussion_r1238880324


More information about the panama-dev mailing list