[foreign-preview] RFR: 8280527: Move jdk.incubator.foreign to java.lang.foreign
Julia Boes
jboes at openjdk.java.net
Tue Jan 25 17:59:52 UTC 2022
On Tue, 25 Jan 2022 12:23:41 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
>> To prepare for preview, this change removes the jdk.incubator.foreign module and moves the public classes to java.base/java.lang.foreign, implementation classes to java.base/jdk.internal.foreign respectively.
>>
>> While here, `SystemLookup` is replaced with the method `ClassLoader::findNative` and the methods in `MemoryHandles` are moved to `MethodHandles`. The `@PreviewFeature(feature=PreviewFeature.Feature.FOREIGN)` annotation and the `--enable-preview` flag are added were needed.
>
> src/hotspot/share/prims/scopedMemoryAccess.cpp line 173:
>
>> 171:
>> 172: #undef CC
>> 173: #undef FN_PTR
>
> Since we're here (but it's ok if we defer it to another PR) we could get rid of the trailing exception parameter in `ScopedMemoryAccess_closeScope`. This was used in a previous iteration of the implementation, but now it's just an unused parameter.
Will address this in https://bugs.openjdk.java.net/browse/JDK-8280596
-------------
PR: https://git.openjdk.java.net/panama-foreign/pull/633
More information about the panama-dev
mailing list