[foreign-jextract] RFR: 8281764: jextract does not generate parameter names for function pointer typedefs [v2]
Athijegannathan Sundararajan
sundar at openjdk.java.net
Mon Feb 21 17:04:40 UTC 2022
On Mon, 21 Feb 2022 10:26:47 GMT, Athijegannathan Sundararajan <sundar at openjdk.org> wrote:
>> src/jdk.incubator.jextract/share/classes/jdk/internal/jextract/impl/TreeMaker.java line 262:
>>
>>> 260: Type.Function funcType = null;
>>> 261: boolean isFuncPtrType = false;
>>> 262: if (canonicalType instanceof Type.Function) {
>>
>> I believe `OutputFactory::getAsFunctionPointer` as code that is similar to this (given a type, return it as a function type - following typedefs if necessary). Maybe we should move this into some util function and share?
>
> That part of the code assumes all Types are properly resolved. In TreeMaker, we're in the middle TypeMaker's construction (resolution happens later).
refactored pointer type check to Utils.java.
-------------
PR: https://git.openjdk.java.net/panama-foreign/pull/646
More information about the panama-dev
mailing list