Skip to content

Instantly share code, notes, and snippets.

@pcpratts
Created February 11, 2013 13:31
Show Gist options
  • Select an option

  • Save pcpratts/4754422 to your computer and use it in GitHub Desktop.

Select an option

Save pcpratts/4754422 to your computer and use it in GitHub Desktop.
patch to make invalid cast work
diff --git a/src/soot/jimple/toolkits/typing/fast/UseChecker.java b/src/soot/jimple/toolkits/typing/fast/UseChecker.java
index 5aa6c65..4472680 100644
--- a/src/soot/jimple/toolkits/typing/fast/UseChecker.java
+++ b/src/soot/jimple/toolkits/typing/fast/UseChecker.java
@@ -184,9 +184,6 @@ public class UseChecker extends AbstractStmtSwitch
else if ( rhs instanceof ArrayRef )
{
this.handleArrayRef((ArrayRef)rhs, stmt);
- if (!(tlhs instanceof BottomType || tlhs instanceof BottomType)) {
- ((ArrayRef)rhs).setBase((Local)this.uv.visit(((ArrayRef)rhs).getBase(), tlhs.makeArrayType(), stmt));
- }
stmt.setRightOp(this.uv.visit(rhs, tlhs, stmt));
}
else if ( rhs instanceof InstanceFieldRef )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment