News for hackers. Stuff that matters.
Re:Networking I/O with Virtual Threads – Under the hood by native_samples on Thursday July 08, 2021 @05:27AM (#27769831)
Well, so far that hasn't been an issue. Kotlin is a pragmatic language. The differences that currently exist can be addressed just with an annotation here or there. Also, Kotlin's features are designed whilst paying careful attention to what the Java guys are doing. Look at how records have played out. You can use JVM records from Kotlin transparently, you can create them by just adding an annotation (not that there's much point in doing so, as records are mostly a labour saving device that Kotlin already had).

Value types are perhaps a better example. Kotlin has them already with nearly identical semantics to Valhalla, but without the ability for them to have more than one field due to the need for erasure. Once Valhalla arrives, Kotlin can simply remove that restriction when targeting the JVM, perhaps add another annotation or compiler flag to say "make this a real Java value type". No language changes needed beyond that.

Kotlin is semantically so close to Java already that they aren't really growing apart, they're growing together. It works well enough to justify its usage, for me.

Re:Networking I/O with Virtual Threads – Under the hood by pjmlp on Thursday July 08, 2021 @06:52AM (#27770357)
JVM history is full of pragmatic guest languages.
Re:Networking I/O with Virtual Threads – Under the hood by native_samples on Thursday July 08, 2021 @09:06AM (#27771420)
Yes, and it's richer for it. Java is definitely not the last word in language design!
Re:Networking I/O with Virtual Threads – Under the hood by pjmlp on Thursday July 08, 2021 @09:45AM (#27771855)
Indeed, it just has the same role on the JVM as C on UNIX, JS on the browser,....

Just like those, it will slowly adopt whatever is more appealing from the guests and then carry on its merry way, while the other slowly lose their relevance while newcomers try yet again to challenge the place of the host language on the platform.