Given the following definitions in v4 applied to the following source:
unpick v4
group int colors
org.example.CommonColors.*
target_method org.example.Main consume (I)V
param 0 colors
public class CommonColors {
public static final int WHITE = -1;
public static final int SOFT_RED = -2142128;
}
...
public static void testUnpick() {
boolean accepted = true;
int inviteColor;
if (accepted) {
inviteColor = CommonColors.SOFT_RED;
} else {
inviteColor = CommonColors.WHITE;
}
consume(inviteColor);
}
public static void consume(int color) {
}
Unpick manage to restore CommonColors.WHITE but not CommonColors.SOFT_RED. It seems the first branch is always ignored in this case, I'm not sure why it happens.
Given the following definitions in v4 applied to the following source:
Unpick manage to restore CommonColors.WHITE but not CommonColors.SOFT_RED. It seems the first branch is always ignored in this case, I'm not sure why it happens.