Bug 100778 - Quick hierarchy: chosen method is not always selected
Summary: Quick hierarchy: chosen method is not always selected
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 minor (vote)
Target Milestone: 3.3 RC4   Edit
Assignee: Frederic Fusier CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-06-20 05:30 EDT by David Saff CLA
Modified: 2007-06-19 09:56 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Saff CLA 2005-06-20 05:30:14 EDT
In RC3.

1) Open Type on java.util.HashMap
2) Place the cursor on put(...), and open the quick type hierarchy.
3) Select ProcessEnvironment

The correct file is opened, but the put(String, String) method is not selected:
the cursor is placed at the very top of the file.

This also seems to show up intermittently in other situations.  For example, at
one point I used quick hierarchy on code like this (types intentionally raw):

List x = new ArrayList();
x.size();

The first time I used Quick Hierarchy to look up Collection.size(), the cursor
was placed about 5 lines below size().  All subsequent times, it correctly
selected and placed the cursor on the declaration of size().  I'm not sure if
these are the same issue.  For me, the ProcessEnvironment bug is solidly
reproduceable.
Comment 1 Dani Megert CLA 2005-06-20 05:35:54 EDT
might be related to bug 100565
Comment 2 Dirk Baeumer CLA 2005-06-20 10:37:22 EDT
This is absolutely strange. I have one workspace wheree process environment does
show up as a subclass of HashMap in this case and one where it doesn't. Both
projects are 5.0.
Comment 3 David Saff CLA 2005-06-20 10:43:06 EDT
Dirk,

Exact same JDK's?
Comment 4 Dirk Baeumer CLA 2005-06-20 11:13:03 EDT
Actually, the problem is that the source range for the method put in
ProcessEnvironment is [-1,0]. Additionally the signature of the put method is
java.lang.Object put(java.lang.Object, java.lang.Object) whereas the method
should be Object put(String, String).

Moving to JDT/Core. 

When trying to reproduce please be aware of bug 100839.
Comment 5 Frederic Fusier CLA 2007-06-19 09:56:33 EDT
Cannot reproduce using 3.3 RC4 whatever the combination used for projects compliance and JRE...