Reading through some of the JEPs for JDK 22 makes ...
# random
e
Reading through some of the JEPs for JDK 22 makes me sad, but also very glad that Kotlin exists 😅
t
😄 which part ?
e
This round it was FFM and String templates
a
Will they ever adopt true null safety? 😅
l
FFM is good I suppose? At least it opens up a whole world. Template is kind of Javaish yeah.
e
It's all good, but the implementations are all, as you say "kind of _Javaish_"
o
FFM is rather good, comparing to JNI The API of FFM is minimal and a little ugly for a reason - it really should not be used without
jextract
(or other code-generator) - with it, the API looks more or less nice and strait-forward, I would say FFM API is low-low-level API, and
jextract
generated API is just low-level API In future (I suppose) there will be better APIs for some stuff. AFAIK even now there talks there regarding mapping struct to `record`s. And a lot more sugar could be added - though, I believe it would be mostly on
jextract
side (and it's expected) Still, with Kotlin we could do better already, but it's a really hard task (
cinterop
is not a good API either)