summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main/java/cuchaz/enigma/analysis/JarIndex.java13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/main/java/cuchaz/enigma/analysis/JarIndex.java b/src/main/java/cuchaz/enigma/analysis/JarIndex.java
index bb36c9ea..ddfdbd69 100644
--- a/src/main/java/cuchaz/enigma/analysis/JarIndex.java
+++ b/src/main/java/cuchaz/enigma/analysis/JarIndex.java
@@ -628,7 +628,7 @@ public class JarIndex {
628 628
629 public Set<MethodEntry> getRelatedMethodImplementations(MethodEntry obfMethodEntry) { 629 public Set<MethodEntry> getRelatedMethodImplementations(MethodEntry obfMethodEntry) {
630 Set<MethodEntry> methodEntries = Sets.newHashSet(); 630 Set<MethodEntry> methodEntries = Sets.newHashSet();
631 getRelatedMethodImplementations(methodEntries, getMethodInheritance(null, obfMethodEntry)); 631 getRelatedMethodImplementations(methodEntries, getMethodInheritance(new Translator(), obfMethodEntry));
632 return methodEntries; 632 return methodEntries;
633 } 633 }
634 634
@@ -639,8 +639,16 @@ public class JarIndex {
639 methodEntries.add(methodEntry); 639 methodEntries.add(methodEntry);
640 } 640 }
641 641
642 // look at bridged methods!
643 // FIXME: looks like a hack to me
644 MethodEntry bridgedEntry = getBridgedMethod(methodEntry);
645 while (bridgedEntry != null) {
646 methodEntries.addAll(getRelatedMethodImplementations(bridgedEntry));
647 bridgedEntry = getBridgedMethod(bridgedEntry);
648 }
649
642 // look at interface methods too 650 // look at interface methods too
643 for (MethodImplementationsTreeNode implementationsNode : getMethodImplementations(null, methodEntry)) { 651 for (MethodImplementationsTreeNode implementationsNode : getMethodImplementations(new Translator(), methodEntry)) {
644 getRelatedMethodImplementations(methodEntries, implementationsNode); 652 getRelatedMethodImplementations(methodEntries, implementationsNode);
645 } 653 }
646 654
@@ -720,7 +728,6 @@ public class JarIndex {
720 } 728 }
721 729
722 public Set<String> getImplementingClasses(String targetInterfaceName) { 730 public Set<String> getImplementingClasses(String targetInterfaceName) {
723
724 // linear search is fast enough for now 731 // linear search is fast enough for now
725 Set<String> classNames = Sets.newHashSet(); 732 Set<String> classNames = Sets.newHashSet();
726 for (Map.Entry<ClassEntry, ClassEntry> entry : this.translationIndex.getClassInterfaces()) { 733 for (Map.Entry<ClassEntry, ClassEntry> entry : this.translationIndex.getClassInterfaces()) {