// These are CstInsn instructions that we need to remove, if
// their constant is a red type.
List<String> instructionsToCheck= Arrays.asList(new String[] { "new-instance", "instance-of", "check-cast", "const-class", "new-array" });
if (instructionsToCheck.contains(opname) && isRedType(constant.toHuman()))
{
dexInstruction= createAssertElement(constant.toHuman(), opname);
}
else
{
dexInstruction.setAttribute("value", constant.toHuman());
}