Hacker News new | ask | show | jobs
by hn_throwaway_99 1736 days ago
I think when Project Loom comes out that Kotlin on top of the JVM will be a tough combo to beat.

Kotlin is basically the language Java should be after 20 years of lessons learned, e.g. language-supported Optionals. The JVM is a battle tested platform. Once Project Loom comes out, you'll get the "best of both worlds" - the easier (i.e. "no functions 'colors'") programming model of multiple threads like in Java, but the scalability and performance of things like async in NodeJS.

3 comments

The biggest real-world benefit of Kotlin is nullity prevention and immutables (of which Optional is a corollary).

It's not clear whether Loom will be a big hit. Personally, I think the Actor model is the best application level concurrency "primitive", and Loom is just about fibers & continuations, both of which are parts of Actors but aren't really Actors themselves.

No, but if your threads are basically 'free' then you can just model an actor as a thread+LinkedBlockingQueue or whatever channel abstraction you want to use.
I think for Kotlin that ship has sailed with the introduction of suspend functions.
I remember reading that you can plug any continuation model into the suspense mechanism?
Java seems to be heading for ML-like features while Kotlin is a "better Java". I think Kotlin lack a vision for the future, and might lose market share as Java itself gets better.
Since Java is now a neglected, second-class, incompatible elder citizen on Android, this is unlikely to happen.
I don't follow Android development at all, so thank you for the correction.