Bug 186788 - [1.5][compiler] Unable to resolve imported member type
Summary: [1.5][compiler] Unable to resolve imported member type
Status: RESOLVED INVALID
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.3 RC1   Edit
Assignee: Kent Johnson CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-05-14 10:03 EDT by Philipe Mulet CLA
Modified: 2007-05-14 12:28 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 Philipe Mulet CLA 2007-05-14 10:03:55 EDT
3.3rc0

The following code is rejected, though javac accepts it:

package p;
import static p.X.Super;
import static p.Top.*;

class Top<T> {
	static class A<U> {}
}

public class X extends Super<A<X>> {
	class Super<T> extends Top<T>{
	}
}
Comment 1 Kent Johnson CLA 2007-05-14 11:55:14 EDT
I'm getting these errors from Eclipse AND javac:

p/X.java:10: cannot find symbol
symbol: class Super
public class X extends Super<A<X>> {
                       ^
p/X.java:10: cannot find symbol
symbol: class A
public class X extends Super<A<X>> {
                             ^
p/X.java:3: cannot find symbol
symbol  : static Super
location: class p.X
import static p.X.Super;
^


and from eclipse:

Super cannot be resolved to a type	z/src/p	X.java	line 10
The import p.X.Super cannot be resolved	z/src/p	X.java	line 3
Comment 2 Kent Johnson CLA 2007-05-14 12:16:15 EDT
Philippe's output directory had other .class files that made the test invalid
Comment 3 Philipe Mulet CLA 2007-05-14 12:28:57 EDT
Added GenericTypeTest#test1140