On Tue, 14 Mar 2023 15:11:36 GMT, Doug Simon <dnsi...@openjdk.org> wrote:

>> Without this declaration, builds fail on Windows with this error:
>> `error C2375: 'c2v_getDeclaredFieldsInfo': redefinition; different linkage`
>
> Strange - thats not needed for other `JVMCIEnv` methods called from 
> `jvmciCompilerToVM.cpp`. There must be some way to avoid this.

The issue was caused by the `friend` declaration below (I cannot remember why I 
added in the first place), which seems to add an implicit declaration of the 
method that was conflicting with the original declaration of the method. Once 
the `friend` declaration is removed, builds on Windows don't need the `extern` 
declaration anymore.

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

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

Reply via email to