What's New in Kotlin 1.3? - Chicago Kotlin User Group
Kotlin 1.3 is finally here and all of the new features aren't going to explain themselves. I gave this presentation to the Chicago Kotlin User Group on 2018-11-20.
val defaultRandom: Random = defaultPlatformRandom() override fun nextInt(): Int = defaultRandom.nextInt() } internal expect fun defaultPlatformRandom(): Random
class Name(val name: String) annotation class PasswordStrategy( val minChars: Int, val minComplexity: Double = 1.0 ) } @Settings.Name("Some kind of provider") @Settings.PasswordStrategy(minChars = 10) class Provider
a single val • No init block • Must be final • Cannot extend anything • Cannot have any additional properties • Must be a top level class • Cannot have inner classes • Cannot be defined with recursively defined generics Limitations!