error: too many constants jextract Windows.h

Maurizio Cimadamore maurizio.cimadamore at oracle.com
Thu Sep 24 18:35:35 UTC 2020


I see that... there are really a tons of functions/constants dropped in 
windows_h.

I recall Jorn having done this at some point, maybe he can provide some 
guidance of what set of filters to add to the command line to end up 
with a reasonable subset?

Maurizio

On 24/09/2020 19:04, Maurizio Cimadamore wrote:
> We already have logic in place to split the underlying constants (e.g. 
> method handles/var handles/layouts) - but this is for the various 
> constant files (here it seems like the error is coming from the main 
> windows_h file).
>
> I'll try to see if I can reproduce - it's mildly surprising to see 
> _that many_ constants ending up in the constant pool here.
>
> Maurizio
>
> On 24/09/2020 05:44, Michael Ennen wrote:
>> Now that the character escaping has been fixed I can get a little bit
>> further trying to compile
>> the jextract result of Windows.h.
>>
>> This time, however, I am running into a Java language limitation:
>>
>> src\main\java\com\dx12\Windows_h.java:10: error: too many constants
>>
>> I am not sure if there is a nice way around this...I remember reading 
>> that
>> the Android library did something to overcome this "limitation" but that
>> was years ago.
>>


More information about the panama-dev mailing list