Bug 5115 - Workspace source locator fails with mulitple package fragments
Summary: Workspace source locator fails with mulitple package fragments
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P1 normal (vote)
Target Milestone: ---   Edit
Assignee: Martin Aeschlimann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-10-19 13:41 EDT by Darin Wright CLA
Modified: 2001-11-13 10:11 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Darin Wright CLA 2001-10-19 13:41:25 EDT
The workspace source locator will not find source in secondary package
fragments. For exmaple, if there are two package fragments "x" in two
projects A and B, and we are looking for "Foo.java" which is defined in project
B - Foo will not be found if project A is seached first.
Comment 1 Darin Wright CLA 2001-10-19 16:20:03 EDT
The workspace source locator is deprecated. Martin, should the Eclipse
launcher be using the ProjectSourceLocator instead?
Comment 2 Martin Aeschlimann CLA 2001-10-22 03:43:47 EDT
We should have a SourceLocator taking an array of projects (ordered).
Comment 3 Darin Wright CLA 2001-10-23 15:33:46 EDT
Fixed
Comment 4 Darin Wright CLA 2001-10-23 15:35:03 EDT
Please verify
Comment 5 Darin Wright CLA 2001-10-23 20:44:19 EDT
This was not fixed. The problem was not multiple fragments between different
projects - the problem was > 1 fragment in the same project in different
source folders/package fragment roots.

Fixed again. The fix is not as efficient as it could be, but it should hold for 
now. The current implementation finds all package fragments in the workspace 
with a given name, and then searches for a type within the fragments. It would 
be better to do the search top down and bail on the first hit (to avoid 
searching for all package fragments).
Comment 6 Darin Wright CLA 2001-10-23 20:44:51 EDT
Sent patch to Jerome and Olivier. Please verify.
Comment 7 Jerome Lanneluc CLA 2001-10-24 06:31:15 EDT
It's worse than before: I don't see any source now.
To reproduce: 
1. Launch Eclipse using the Eclipse launcher under debug.
2. Suspend the main thread
3. Select the OS.WaitMessage() stack frame
Observe: No source is displayed.

Note my project's locations are all inside my workspace.
Comment 8 Martin Aeschlimann CLA 2001-11-01 04:54:30 EST
The workspace source locator is not used anymore.
Jerome confirmed (email) that it's working now.

11025
Comment 9 Darin Wright CLA 2001-11-13 10:11:09 EST
Verified.