ifnull
This commit is contained in:
@@ -33,6 +33,10 @@ public class IfNull extends If0
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (otherIc.getInstruction() instanceof IfNonNull)
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -40,7 +44,7 @@ public class IfNull extends If0
|
|||||||
@Override
|
@Override
|
||||||
public void map(ParallelExecutorMapping mapping, InstructionContext ctx, InstructionContext other)
|
public void map(ParallelExecutorMapping mapping, InstructionContext ctx, InstructionContext other)
|
||||||
{
|
{
|
||||||
if (other.getInstruction() instanceof IfACmpNe)
|
if (other.getInstruction() instanceof IfACmpNe || other.getInstruction() instanceof IfNonNull)
|
||||||
{
|
{
|
||||||
super.mapOtherBranch(mapping, ctx, other);
|
super.mapOtherBranch(mapping, ctx, other);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ public class MapStaticTest
|
|||||||
{ "class29.method711", "class36.method742" },
|
{ "class29.method711", "class36.method742" },
|
||||||
{ "class72.run", "class72.run" },
|
{ "class72.run", "class72.run" },
|
||||||
{ "class64.vmethod3787", "class64.vmethod3664" },
|
{ "class64.vmethod3787", "class64.vmethod3664" },
|
||||||
|
{ "class207.method3965", "class207.method3846" },
|
||||||
};
|
};
|
||||||
|
|
||||||
// @Test
|
// @Test
|
||||||
@@ -80,8 +81,8 @@ public class MapStaticTest
|
|||||||
ClassGroup group1 = JarUtil.loadJar(new File("d:/rs/07/adamin1.jar"));
|
ClassGroup group1 = JarUtil.loadJar(new File("d:/rs/07/adamin1.jar"));
|
||||||
ClassGroup group2 = JarUtil.loadJar(new File("d:/rs/07/adamin2.jar"));
|
ClassGroup group2 = JarUtil.loadJar(new File("d:/rs/07/adamin2.jar"));
|
||||||
|
|
||||||
Method m1 = group1.findClass("class64").findMethod("vmethod3787");
|
Method m1 = group1.findClass("class207").findMethod("method3965");
|
||||||
Method m2 = group2.findClass("class64").findMethod("vmethod3664");
|
Method m2 = group2.findClass("class207").findMethod("method3846");
|
||||||
|
|
||||||
ParallelExecutorMapping mappings = MappingExecutorUtil.map(m1, m2);
|
ParallelExecutorMapping mappings = MappingExecutorUtil.map(m1, m2);
|
||||||
|
|
||||||
@@ -98,8 +99,8 @@ public class MapStaticTest
|
|||||||
ClassGroup group1 = JarUtil.loadJar(new File("d:/rs/07/adamin1.jar"));
|
ClassGroup group1 = JarUtil.loadJar(new File("d:/rs/07/adamin1.jar"));
|
||||||
ClassGroup group2 = JarUtil.loadJar(new File("d:/rs/07/adamin2.jar"));
|
ClassGroup group2 = JarUtil.loadJar(new File("d:/rs/07/adamin2.jar"));
|
||||||
|
|
||||||
Method m1 = group1.findClass("class64").findMethod("vmethod3787");
|
Method m1 = group1.findClass("class207").findMethod("method3965");
|
||||||
Method m2 = group2.findClass("class64").findMethod("vmethod3664");
|
Method m2 = group2.findClass("class207").findMethod("method3846");
|
||||||
|
|
||||||
HashMap<Object, Object> all = new HashMap();
|
HashMap<Object, Object> all = new HashMap();
|
||||||
map(all, new HashSet(), m1, m2);
|
map(all, new HashSet(), m1, m2);
|
||||||
|
|||||||
Reference in New Issue
Block a user