Pointer/Scope API questions
Ty Young
youngty1997 at gmail.com
Wed Jan 8 10:51:59 UTC 2020
>>
>> BTW, is there something wrong with the memaccess-jextract branch?
>> I've compiled it, enabled preview features, and added the
>> jdk.incubator.foreign and jdk.incubator.jextract modules but get an
>> exception when attempting to run the classes at runtime:
>>
>>
>> Exception in thread "main" java.lang.NoClassDefFoundError:
>> jdk/incubator/foreign/SystemABI
>> at
>> org.goliath.panamamemtest.PanamaMemTest.main(PanamaMemTest.java:30)
>> Caused by: java.lang.ClassNotFoundException:
>> jdk.incubator.foreign.SystemABI
>> at
>> java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:602)
>> at
>> java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
>> at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:523)
>>
>>
>> Maven 3.6.2 with release set explicitly to Java 15.
>>
>>
>> The same goes for the jextract module. Given that I can require the
>> module and import the classes I'm a bit confused as to why it's doing
>> this. The jmods are visible in the JDK builds so... yeah.
>>
> Are you also adding `--add-modules
> jdk.incubator.foreign,jdk.incubator.jextract` when running? I was
> seeing a similar error when I forgot to do that.
Ah, no. Works now.
Is it supposed to throw an exception there though? The modules are apart
of the JDK and preview features are enabled so I don't understand why
the extra step of adding the modules at runtime is being required here.
Is it a bug?
>
> Jorn
>
>>> Maurizio
>>>
More information about the panama-dev
mailing list