konsoletyper 2014-11-03 20:31:49 +03:00
parent e934ddc798
commit 9be6ce9bbf
2 changed files with 8 additions and 2 deletions

View File

@ -225,7 +225,7 @@ public class DependencyChecker implements DependencyInfo, DependencyAgent {
if (dependency.isMissing()) {
missingClasses.add(dependency);
} else {
if (cls.getParent() != null) {
if (cls.getParent() != null && !cls.getParent().equals(className)) {
linkClass(cls.getParent(), stack);
}
for (String ifaceName : cls.getInterfaces()) {
@ -267,7 +267,7 @@ public class DependencyChecker implements DependencyInfo, DependencyAgent {
if (reader != null) {
return reader;
}
if (cls.getParent() != null) {
if (cls.getParent() != null && cls.getParent().equals(cls.getParent())) {
reader = methodReaderCache.map(new MethodReference(cls.getParent(), desc));
if (reader != null) {
return reader;
@ -294,6 +294,9 @@ public class DependencyChecker implements DependencyInfo, DependencyAgent {
if (field != null) {
return field;
}
if (clsName.equals(cls.getParent())) {
break;
}
clsName = cls.getParent();
}
return null;

View File

@ -55,6 +55,9 @@ public final class Parser {
if (node.superName != null) {
cls.setParent(node.superName.replace('/', '.'));
}
if (cls.getName().equals("java.lang.Object")) {
cls.setParent(null);
}
if (node.interfaces != null) {
for (Object obj : node.interfaces) {
cls.getInterfaces().add(((String)obj).replace('/', '.'));