Bug 25539 - Unexpected inaccurate search results
Summary: Unexpected inaccurate search results
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 2.1 M3   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-10-30 09:31 EST by Philipe Mulet CLA
Modified: 2002-11-25 07:49 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philipe Mulet CLA 2002-10-30 09:31:51 EST
Build 20021029

When searching for references to Throwable (type references), I got back 
inaccurate matches, such as:

org.eclipse.jdt.core.tests.compiler.parser.SingleCompletionTest.run(Class, 
String)

org.eclipse.core.runtime.IStatus.getException()

(got 51 inaccurate matches in total)
Comment 1 Philipe Mulet CLA 2002-10-30 11:29:17 EST
Forgot to mention the search was not case sensitive.
Comment 2 Jerome Lanneluc CLA 2002-10-31 10:55:53 EST
There were 2 problems:
- the pattern didn't need resolve, but since SingleNameReferences were found we 
resolved only the current unit. This caused binary types of another potential 
match to be cached in the LookupEnvironment and thus when resolving this other 
potential match, a duplicate type error was reported, and resolution aborted.
- in presence of binary types and their member types (e.g. A.class and 
A$B.class), 2 resolution were done. The second failed with a duplicate type 
error.

Fixed first problem by resolving all potential matches at once if we find out 
that resolution is needed late in the game.

Fixed second problem by remembering that a unit had already been resolved.