It might be needed to pass the address of a native function to another native function as a callback.
Right now it is not possible to get the address of a native function through jextract, though. A user could create an upcall stub that points to the Java method wrapping the native function. but that needlessly incurs an additional trip trough Java when the callback is called. Alternatively, a user would have to edit the code generated by jextract to expose the function address, or load the library themselves and then look up the function address. Neither of these are convenient workaround.
We should generate an accessor for the address of a native function as well.
Right now it is not possible to get the address of a native function through jextract, though. A user could create an upcall stub that points to the Java method wrapping the native function. but that needlessly incurs an additional trip trough Java when the callback is called. Alternatively, a user would have to edit the code generated by jextract to expose the function address, or load the library themselves and then look up the function address. Neither of these are convenient workaround.
We should generate an accessor for the address of a native function as well.