Hello, there are any problems that if always using...
# getting-started
u
Hello, there are any problems that if always using the latest kotlin version? In my project, i use 1.5.21 versioin and use jvm target 1.8. And im considering upgrade version to 1.7.20. If i use jvm target 1.8, there are no matters that using latest kotlin version?
s
not that I know of. As long as the jvm target is supported by the Kotlin version, it can be targeted by that Kotlin version. At some point an old jvm target will be removed though, e.g. Kotlin used to support a jdk-target of 1.6 but that has ended. But jdk1.8 is still supported by Kotlin1.8. In general, it is a good idea to update to the latest LTS version of the jdk (currently 17, soon 21) simply to cash in on improvements of the jvm like better String compression, more efficient GC or increased security. But sometimes we want to use features that where removed (e.g. some cryptographic algorithms were removed in jdk 14/15, so in that case I'd stay with jdk 11 (which is also LTS)).
🙌 2