-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: implement new type inference approach
- Loading branch information
Showing
94 changed files
with
3,067 additions
and
1,546 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,3 +29,4 @@ jadx-output/ | |
*.dump | ||
*.log | ||
*.cfg | ||
*.orig |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
jadx-core/src/main/java/jadx/core/dex/attributes/nodes/LocalVarsDebugInfoAttr.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
package jadx.core.dex.attributes.nodes; | ||
|
||
import java.util.List; | ||
|
||
import jadx.core.dex.attributes.AType; | ||
import jadx.core.dex.attributes.IAttribute; | ||
import jadx.core.dex.visitors.debuginfo.LocalVar; | ||
import jadx.core.utils.Utils; | ||
|
||
public class LocalVarsDebugInfoAttr implements IAttribute { | ||
private final List<LocalVar> localVars; | ||
|
||
public LocalVarsDebugInfoAttr(List<LocalVar> localVars) { | ||
this.localVars = localVars; | ||
} | ||
|
||
public List<LocalVar> getLocalVars() { | ||
return localVars; | ||
} | ||
|
||
@Override | ||
public AType<LocalVarsDebugInfoAttr> getType() { | ||
return AType.LOCAL_VARS_DEBUG_INFO; | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return "Debug Info:\n " + Utils.listToString(localVars, "\n "); | ||
} | ||
} |
58 changes: 58 additions & 0 deletions
58
jadx-core/src/main/java/jadx/core/dex/attributes/nodes/RegDebugInfoAttr.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
package jadx.core.dex.attributes.nodes; | ||
|
||
import java.util.Objects; | ||
|
||
import jadx.core.dex.attributes.AType; | ||
import jadx.core.dex.attributes.IAttribute; | ||
import jadx.core.dex.instructions.args.ArgType; | ||
import jadx.core.dex.visitors.debuginfo.LocalVar; | ||
|
||
public class RegDebugInfoAttr implements IAttribute { | ||
|
||
private final ArgType type; | ||
private final String name; | ||
|
||
public RegDebugInfoAttr(LocalVar var) { | ||
this(var.getType(), var.getName()); | ||
} | ||
|
||
public RegDebugInfoAttr(ArgType type, String name) { | ||
this.type = type; | ||
this.name = name; | ||
} | ||
|
||
public String getName() { | ||
return name; | ||
} | ||
|
||
public ArgType getRegType() { | ||
return type; | ||
} | ||
|
||
@Override | ||
public AType getType() { | ||
return AType.REG_DEBUG_INFO; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) { | ||
return true; | ||
} | ||
if (o == null || getClass() != o.getClass()) { | ||
return false; | ||
} | ||
RegDebugInfoAttr that = (RegDebugInfoAttr) o; | ||
return Objects.equals(type, that.type) && Objects.equals(name, that.name); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(type, name); | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return "D('" + name + "' " + type + ")"; | ||
} | ||
} |
Oops, something went wrong.