inline class can be declared as `inline class` and...
# announcements
m
inline class can be declared as
inline class
and
value class
. why do both declarations exist? will one of them be dropped in stable release?
a
https://blog.jetbrains.com/kotlin/2021/02/new-language-features-preview-in-kotlin-1-4-30
You define a value class with one constructor parameter and annotate it with 
@JvmInline
. We expect everyone to use this new syntax starting from Kotlin 1.5. The old syntax 
inline class
 will continue to work for some time. It will be deprecated with a warning in 1.5 that will include an option to migrate all your declarations automatically. It will later be deprecated with an error.
m
@Albert Chang thanks
j
A bit confusing that the blog post is started with an introduction to inline classes using the about to be deprecated syntax... 😅
😃 1