Hacker News new | ask | show | jobs
by farmerbb 1546 days ago
> Kotlin for most of the backend code, but Java for shared libs. We still use Java 8 for some libs which may be used in Android, that's an unfortunate reality

Considering Kotlin is a supported, first-class language on Android, why not write your shared libs in Kotlin as well?

1 comments

I'm talking about open-source libs, i.e., I don't know who is going to use the lib, which env and target language they have, etc.

So I think that Java is the best middle ground here because it guaranties the full support of JVM features and 3rd party tools. I mean just avoiding a risk that it would be incompatible with something.