You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using Kotlin coroutine 1.3.2, and my app is obfuscated. When I using coroutines, I get the following crash stack:
java.lang.RuntimeException: java.lang.NoSuchFieldException: No field result in class Lkotlin/f/i;
java.util.concurrent.atomic.AtomicReferenceFieldUpdater$AtomicReferenceFieldUpdaterImpl.<init>(AtomicReferenceFieldUpdater.java:338)
at java.util.concurrent.atomic.AtomicReferenceFieldUpdater.newUpdater(AtomicReferenceFieldUpdater.java:109)
at kotlin.coroutines.SafeContinuation.<clinit>(SourceFile:31)
According to the mapping file, the class Lkotlin/f/i is actually SafeContinuation. I look into SafeContinuation, there is a field named result, and it is volatile.
I also noticed that the Kotlin extension library's proguard file has kept all volatile field. So I guess it is also necessary to keep all volatile in Kotlin's stdlib?
The text was updated successfully, but these errors were encountered:
fightyz
changed the title
Missing Proguard rules? Crash on 'java.lang.NoSuchFieldException: No field result in class Lkotlin/f/i;'
Missing Proguard rules? Crash at 'java.lang.NoSuchFieldException: No field result in class Lkotlin/f/i;'
Dec 9, 2019
I'm using Kotlin coroutine 1.3.2, and my app is obfuscated. When I using coroutines, I get the following crash stack:
According to the mapping file, the class
Lkotlin/f/i
is actuallySafeContinuation
. I look intoSafeContinuation
, there is a field namedresult
, and it isvolatile
.I also noticed that the Kotlin extension library's proguard file has kept all volatile field. So I guess it is also necessary to keep all volatile in Kotlin's stdlib?
The text was updated successfully, but these errors were encountered: