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

Commit 9d27a928 authored by Jared Duke's avatar Jared Duke
Browse files

Only keep Parcelables if used

Use `-keepclassmembers` instead of `-keep` for Parcelable types
and their CREATOR members. This allows shrinking of Parcelable types
that aren't referenced while still preserving the necessary CREATOR
member when the classes are kept. This saves ~3MB across various
platform targets.

Bug: 238670321
Test: m + presubmit
Change-Id: I13508073dbc07e28aa93bb6604c8f838bcf72646
parent 2a9b910b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -53,7 +53,7 @@
# -keep class * extends android.app.BackupAgent

# Parcelable CREATORs must be kept for Parcelable functionality
-keep class * implements android.os.Parcelable {
-keepclassmembers class * implements android.os.Parcelable {
  public static final ** CREATOR;
}