Generic inline classes in Kotlin 1.7.20

preview_player
Показать описание
Inline classes in Kotlin are all about bringing value semantics to the language – to introduce objects where only their actual values count, but not their identity. In Kotlin 1.7.20, they’re getting one step better: Under a new experimental flag, you can make inline classes generic for the first time!

Рекомендации по теме
Комментарии
Автор

Hey, I Sebastian, I just wanted to say that you look great.

kaopesa
Автор

‪In the video a custom data class will be wrapped in an inline class, but in the documentation explicitly primitive values will be mentioned - why are both allowed and what sense does wrapping the custom class with potentially multiple properties make?‬

AndrasHatvani
Автор

Im using IntelliJ IDEA 2022.2.3 (Community Edition), and have updated my `plugins Kotlin("jvm") version "1.7.20"`, and added the `kotlinOptions.languageVersion="1.8"`, and the compiler is complaining about the generic parameter on the `HighQuality` value class.

Is it possible to post this project to a github to see what Im missing here?

ChrisAthanas
Автор

Why does IDEA look so much different on Mac

AhmadSattout
Автор

Amazing toturials! Thanks!
Anyways, you look different :)

mohsenrzna
Автор

another extra key word value? Happy refactoring...

yangqiou
Автор

So, if I start using generic inline classes from java, I could still get runtime error, because we will have `Object foo` in some cases, right?

Denis-ezgd
visit shbcf.ru