RFR: 7903449: Jextract generates structs that cannot be compiled [v3]
Maurizio Cimadamore
mcimadamore at openjdk.org
Tue Mar 28 22:44:55 UTC 2023
On Tue, 28 Mar 2023 15:55:35 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:
>> Maurizio Cimadamore has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Share more constants
>
> src/main/java/org/openjdk/jextract/impl/Constants.java line 506:
>
>> 504: record DowncallKey(FunctionDescriptor desc) { }
>> 505: DowncallKey downcallKey = new DowncallKey(descriptor);
>> 506: Constant constant = cache.get(downcallKey);
>
> Isn't dropping the names from the layouts required here as well?
Likely, if we want to deduplicate fully. I'm a bit worried about doing a full traversal and creating a brand new function descriptor just for the lookup though. I guess I could implement some custom equals method in the key.
-------------
PR Review Comment: https://git.openjdk.org/jextract/pull/117#discussion_r1151221349
More information about the jextract-dev
mailing list