Note that nowadays with Panama, there are more FFI opportunities in JVM implementations as well.
Although it is rather verbose, and it is easier to have a C header and run jextract on it, instead of the manual boilerplate.
No idea how well AI tooling would manage.