Skip to content

Commit 2e5c66e

Browse files
authored
Fixed VerifyError after ProGuard optimization (#2728)
Disabled optimisation for descriptor field because in some versions of ProGuard, optimization generates incorrect bytecode that causes a verification error. Fixes #2719
1 parent 66fc048 commit 2e5c66e

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

rules/common.pro

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,9 @@
3333
# If there is no `java.lang.ClassValue` (for example, in Android), then R8/ProGuard will print a warning.
3434
# However, since in this case they will not be used, we can disable these warnings
3535
-dontwarn kotlinx.serialization.internal.ClassValueReferences
36+
37+
# disable optimisation for descriptor field because in some versions of ProGuard, optimization generates incorrect bytecode that causes a verification error
38+
# see https://github.com/Kotlin/kotlinx.serialization/issues/2719
39+
-keepclassmembers public class **$$serializer {
40+
private ** descriptor;
41+
}

0 commit comments

Comments
 (0)