3 ms·
Kotlin has the best java interop for any of the JVM languages, so you don't have to rewrite everything in kotlin . You can gradually migrate while using the sam
by SureshG 9y ago
Kotlin has the best java interop for any of the JVM languages, so you don't have to rewrite everything in kotlin . You can gradually migrate while using the same tooling.
- zmmmmm 9y agoInterested in how you think Kotlin interop is better than Groovy? Curious because that to me is one of the main things that makes me choose Groovy in some situations over other languages (eg: Scala, Clojure, Jython, etc) where the impedance mismatch is much higher.
- cesarb 9y agoAnd related to the parent comment: Kotlin's compiler understands several kinds of @Nullable/@NotNull/@Nonnull annotations, and treats them as Kotlin's nullable/not nullable ("@Nullable String" is treated as String?, for instance). In the other direction, Kotlin's nullable/not nullable is visible to the Java side as one of these sets of annotations (IntelliJ's IIRC), which allows for instance annotation processors like Dagger 2 to know when something can be null or not.