[foreign] RFR 8217462: Add a jextract option to not generate typedef annotation interfaces
Maurizio Cimadamore
maurizio.cimadamore at oracle.com
Tue Jan 22 21:10:00 UTC 2019
Hi Jorn,
while I understand where you are coming from, I'd like not to fragment
the space of the jextract options too much - as discussed earlier today,
there is already enough confusion over existing options, and we should
clear that before adding new ones :-)
Also, if we go down this path, I'm afraid that this will turn into
having a full menu of options to support this or that generation tweak -
this sort of things tend to add up, the options will likely be (ab)used
in any possible configuration, with the result that the jextract output
will be perceived as something not stable.
I have also a sense that your request is coming in part from issues that
were pointed out few days ago - e.g. jextract is currently generating
too much stuff - even things that have nothing to do with the library
being extracted (but which is recursively included by the headers). As
we have said then, the solution for this problem is to adopt a
library-centric approach, not adding custom flags to selectively switch
off extraction features.
Maurizio
On 22/01/2019 19:48, Jorn Vernee wrote:
> Hi,
>
> From the bug description:
>
> Currently jextract generates annotation interfaces for typedefs. But,
> using these annotations is not required to call the native functions
> defined in a library. Rather, they are there to add additional
> metadata to java carrier types.
>
> Since use of these annotations interfaces is optional, it would be
> nice to have a jextract option to turn of their generation, in order
> to simplify generated classes (especially useful when viewing them
> with a decompiler/javap)
>
> Please review the following.
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-8217462
> Webrev:
> http://cr.openjdk.java.net/~jvernee/panama/webrevs/8217462/webrev.00/
>
> Thanks,
> Jorn
More information about the panama-dev
mailing list