Skip to content

Commit 29975c1

Browse files
Rob Strykerdatho7561
authored andcommitted
Only add unresolved matches when there's some part that matches
Signed-off-by: Rob Stryker <[email protected]>
1 parent a7d5cec commit 29975c1

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

org.eclipse.jdt.core.javac/src/org/eclipse/jdt/core/dom/JavacBindingResolver.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -592,7 +592,8 @@ record Pair(JavacTypeBinding binding, int weight) {};
592592
}
593593
}
594594
}
595-
collector.add(new Pair(x, total));
595+
if( total > 0 )
596+
collector.add(new Pair(x, total));
596597
});
597598

598599
Collections.sort(collector, (o1, o2) -> o2.weight - o1.weight);

0 commit comments

Comments
 (0)