Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jadx
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open-source
jadx
Commits
cc318b13
Commit
cc318b13
authored
Apr 12, 2013
by
Skylot
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ArgType refactoring, add generic parsing
parent
d662b2c5
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
261 additions
and
114 deletions
+261
-114
InsnGen.java
src/main/java/jadx/codegen/InsnGen.java
+12
-4
LocalVarInfo.java
src/main/java/jadx/dex/info/LocalVarInfo.java
+1
-1
ArgType.java
src/main/java/jadx/dex/instructions/args/ArgType.java
+247
-106
PrimitiveType.java
src/main/java/jadx/dex/instructions/args/PrimitiveType.java
+1
-1
MethodNode.java
src/main/java/jadx/dex/nodes/MethodNode.java
+0
-2
No files found.
src/main/java/jadx/codegen/InsnGen.java
View file @
cc318b13
...
...
@@ -94,10 +94,18 @@ public class InsnGen {
}
public
String
declareVar
(
RegisterArg
arg
)
throws
CodegenException
{
String
type
=
TypeGen
.
translate
(
mgen
.
getClassGen
(),
arg
.
getType
());
String
generic
=
arg
.
getType
().
getGeneric
();
if
(
generic
!=
null
)
type
+=
" /* "
+
generic
+
" */"
;
String
type
=
useType
(
arg
.
getType
());
ArgType
[]
generics
=
arg
.
getType
().
getGenericTypes
();
if
(
generics
!=
null
)
{
StringBuilder
sb
=
new
StringBuilder
();
sb
.
append
(
type
);
sb
.
append
(
"/*<"
);
for
(
ArgType
gt
:
generics
)
{
sb
.
append
(
useType
(
gt
));
}
sb
.
append
(
">*/"
);
type
=
sb
.
toString
();
}
return
type
+
" "
+
arg
(
arg
);
}
...
...
src/main/java/jadx/dex/info/LocalVarInfo.java
View file @
cc318b13
...
...
@@ -28,7 +28,7 @@ public class LocalVarInfo extends RegisterArg {
private
void
init
(
String
name
,
ArgType
type
,
String
sign
)
{
if
(
sign
!=
null
)
{
type
.
setGeneric
(
sign
);
type
=
ArgType
.
generic
(
type
.
getObject
(),
sign
);
}
TypedVar
tv
=
new
TypedVar
(
type
);
tv
.
setName
(
name
);
...
...
src/main/java/jadx/dex/instructions/args/ArgType.java
View file @
cc318b13
This diff is collapsed.
Click to expand it.
src/main/java/jadx/dex/instructions/args/PrimitiveType.java
View file @
cc318b13
...
...
@@ -45,6 +45,6 @@ public enum PrimitiveType {
@Override
public
String
toString
()
{
return
this
.
name
().
toLowerCase
()
;
return
longName
;
}
}
src/main/java/jadx/dex/nodes/MethodNode.java
View file @
cc318b13
...
...
@@ -109,8 +109,6 @@ public class MethodNode extends AttrNode implements ILoadable {
return
;
if
(
instructions
!=
null
)
instructions
.
clear
();
// if (blocks != null) blocks.clear();
// if (exitBlocks != null) exitBlocks.clear();
blocks
=
null
;
exitBlocks
=
null
;
if
(
exceptionHandlers
!=
null
)
exceptionHandlers
.
clear
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment