Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 54c1f7ce authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Add keep rules for @KeepForWeakReference annotation" am: 3eb3ca0c am: 41437def

parents 5fa9538f 41437def
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -15,6 +15,12 @@
@**.VisibleForTesting *;
}

# Keep rule for members that are needed solely to keep alive downstream weak
# references, and could otherwise be removed after tree shaking optimizations.
-keepclassmembers,allowaccessmodification,allowobfuscation,allowshrinking class * {
  @com.android.internal.annotations.KeepForWeakReference <fields>;
}

# Understand the common @Keep annotation from various Android packages:
#  * android.support.annotation
#  * androidx.annotation