View | Details | Raw Unified | Return to bug 97547 | Differences between
and this patch

Collapse All | Expand All

(-)search/org/eclipse/jdt/internal/core/search/matching/PackageReferenceLocator.java (-7 / +1 lines)
Lines 90-102 Link Here
90
}
90
}
91
91
92
protected int matchLevel(ImportReference importRef) {
92
protected int matchLevel(ImportReference importRef) {
93
	// Compare prefix also for static import
93
	return matchLevelForTokens(importRef.tokens);
94
	if (!importRef.onDemand || importRef.isStatic())
95
		return matchLevelForTokens(importRef.tokens);
96
97
	return matchesName(this.pattern.pkgName, CharOperation.concatWith(importRef.tokens, '.'))
98
		? ACCURATE_MATCH
99
		: IMPOSSIBLE_MATCH;
100
}
94
}
101
protected int matchLevelForTokens(char[][] tokens) {
95
protected int matchLevelForTokens(char[][] tokens) {
102
	if (this.pattern.pkgName == null) return ACCURATE_MATCH;
96
	if (this.pattern.pkgName == null) return ACCURATE_MATCH;

Return to bug 97547