On Wed, 23 Nov 2022 17:33:06 GMT, Maurizio Cimadamore <mcimadam...@openjdk.org> 
wrote:

>> This PR contains the API and implementation changes for JEP-434 [1]. A more 
>> detailed description of such changes, to avoid repetitions during the review 
>> process, is included as a separate comment.
>> 
>> [1] - https://openjdk.org/jeps/434
>
> Maurizio Cimadamore has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   * remove unused Scoped interface
>   * re-add trusting of final fields in layout class implementations
>   * Fix BulkOps benchmark, which had alignment issues

Marked as reviewed by psandoz (Reviewer).

src/java.base/share/classes/jdk/internal/foreign/FunctionDescriptorImpl.java 
line 57:

> 55:      * {@return the return layout (if any) associated with this function 
> descriptor}
> 56:      */
> 57:     public final Optional<MemoryLayout> returnLayout() {

No need for `final` since class is final.

Suggestion:

    public Optional<MemoryLayout> returnLayout() {

src/java.base/share/classes/jdk/internal/foreign/SlicingAllocator.java line 33:

> 31: public final class SlicingAllocator implements SegmentAllocator {
> 32: 
> 33:     public static final long DEFAULT_BLOCK_SIZE = 4 * 1024;

Not used.

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

PR: https://git.openjdk.org/jdk/pull/10872

Reply via email to