-
Notifications
You must be signed in to change notification settings - Fork 540
Open
Labels
bugSomething isn't workingSomething isn't working
Description
This is the error that I'd encountered:
Exception in thread "main" java.lang.ExceptionInInitializerError
at a.a(Unknown Source)
at uC.<init>(Unknown Source)
at uz.a(Unknown Source)
at main(Unknown Source)
Caused by: java.lang.RuntimeException: java.lang.NoSuchFieldException: chars
at java.base/java.util.concurrent.atomic.AtomicReferenceFieldUpdater$AtomicReferenceFieldUpdaterImpl.<init>(AtomicReferenceFieldUpdater.java:334)
at java.base/java.util.concurrent.atomic.AtomicReferenceFieldUpdater.newUpdater(AtomicReferenceFieldUpdater.java:112)
at f.<clinit>(Unknown Source)
... 4 more
Caused by: java.lang.NoSuchFieldException: chars
at java.base/java.lang.Class.getDeclaredField(Class.java:2384)
at java.base/java.util.concurrent.atomic.AtomicReferenceFieldUpdater$AtomicReferenceFieldUpdaterImpl.<init>(AtomicReferenceFieldUpdater.java:328)
... 6 more
And these are the rules that I'd added
-keepclassmembers class com.alibaba.fastjson2.JSONFactory$CacheItem {<fields>;}
-keepclassmembers class com.alibaba.fastjson2.util.TypeUtils$Cache {<fields>;}
I think that the document should be updated. These are the optimized proguard rules
-keepclassmembers class com.alibaba.fastjson2.JSONFactory$CacheItem {<fields>;}
-keepclassmembers class com.alibaba.fastjson2.util.TypeUtils$Cache {<fields>;}
-keep, allowoptimization, allowobfuscation @com.alibaba.fastjson2.annotation.JSONType class *
# Keep the fields and methods with @JSONField
-keepclassmembers, allowobfuscation class * {
@com.alibaba.fastjson2.annotation.JSONField <fields>;
@com.alibaba.fastjson2.annotation.JSONField <methods>;
}
# Keep any (anonymous) classes extending TypeReference
-keep, allowobfuscation class com.alibaba.fastjson2.TypeReference
-keep, allowobfuscation class * extends com.alibaba.fastjson2.TypeReference
wenshao
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working