Bug 42365 - Open on selection does not work for method inside interface
Summary: Open on selection does not work for method inside interface
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.0 M6   Edit
Assignee: David Audel CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-02 04:52 EDT by David Audel CLA
Modified: 2003-12-16 06:35 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 David Audel CLA 2003-09-02 04:52:11 EDT
1) create the x.jar file with the following classes
I.class
public interface I {
	void foo();
}

X.class
public abstract class X implements I{

}

Y.class
public class Y extends X {
	public void foo() {
	}
}
2) attache source file to this jar
3) create the following class
Z.java
public class Z {
	public static void main(String[] args) {
		Y y = new Y();
		((X)y).foo();//select foo
	}
}
4) select 'foo' in the commented line
5) do F3

X.class is selected but it must be I.class

The problem does not happen if I, X and Y are in source file.
Comment 1 David Audel CLA 2003-12-11 11:12:35 EST
The problem does not occurs in build 20031211

Test added (ResolveTests#testMethodDeclarationInInterface)

Fixed.
Comment 2 Frederic Fusier CLA 2003-12-16 06:00:19 EST
Verified with build I200312160010
Comment 3 David Audel CLA 2003-12-16 06:34:21 EST
Change status
Comment 4 David Audel CLA 2003-12-16 06:35:08 EST
Change status to workforme