Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

When ProGuard is enabled for an Android project with Kotlin, the Gradle build fails with the following error:

Warning: HomeChargerLocation: can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

Warning: HomeChargerLocation$Address: can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

Warning: HomeChargerLocation$Address$Creator: can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

Warning: HomeChargerLocation$Car: can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

Warning: HomeChargerLocation$Car$Creator: can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

Warning: HomeChargerLocation$Creator: can't find referenced class kotlin.internal.annotations.AvoidUninitializedObjectCopyingCheck

Warning: Exception while processing task java.io.IOException: Please correct the above warnings first.

The corresponding classes: https://gist.github.com/makovkastar/cfa4bf1bea38556279f20eef46001cf8

I assume it has something to do with the @Parcelize annotation from the Kotlin experimental package, because the problem appeared when we started using it.

UPDATE: I have created an issue in the Kotlin bug tracker - https://youtrack.jetbrains.com/issue/KT-21628

like image 407
makovkastar Avatar asked Dec 05 '17 13:12

makovkastar


1 Answers

The issue has been fixed in Kotlin 1.2.20.

like image 165
makovkastar Avatar answered Oct 19 '22 16:10

makovkastar