I write -assumenosideeffects class android.util.Log
in my app. but how to use this.
-assumenosideeffects class android.util.Log
{
public static int d(...);
public static int v(...);
public static int i(...);
public static int e(...);
}
in proguard.cfg
file. but not working.
The below one works exactly
Similarly you can use i, v and e.
Forgot 'public' access modifier?
The manual says
-assumenosideffects
is "Only applicable when optimizing".${sdk.dir}/tools/proguard/proguard-android.txt
says: "Optimization is turned off by default. Dex does not like code run through the ProGuard optimize and preverify steps".http://researcharea.blogspot.com/2012/04/assumenosideeffects-not-working-in.html
According to @Sean Owen and @Yevgen Kulik.
In Gradle, use this:
Then add below to your proguard-rules.pro
Try
-assumenosideeffects class android.util.Log { public * ; }
. If that doesn't work, post why you think it isn't working.