[foreign-jextract] RFR: CSupport::getSystemLinker should not be called from internal API points
Athijegannathan Sundararajan
sundar at openjdk.java.net
Tue Jun 9 10:53:31 UTC 2020
On Tue, 9 Jun 2020 10:22:21 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:
> Some jextract internal classes call the external getSystemLinker method, which then does a check on the
> `foreign.restricted` property (which is disabled when jextract runs). Trusted internal API points should use the
> internal factory for the system linker instead.
Marked as reviewed by sundar (Committer).
src/jdk.incubator.jextract/share/classes/jdk/internal/jextract/impl/LayoutUtils.java line 200:
> 199: case 32: return Primitive.Kind.Int;
> 200: case 64: return SharedUtils.getSystemLinker().name().equals(CSupport.Win64.NAME) ?
> 201: Primitive.Kind.LongLong : Primitive.Kind.Long;
could use static field "abi" instead?
-------------
PR: https://git.openjdk.java.net/panama-foreign/pull/198
More information about the panama-dev
mailing list