Bug 94644

Summary: [1.5][compiler] Non-static member type of raw type should be raw
Product: [Eclipse Project] JDT Reporter: Philipe Mulet <philippe_mulet>
Component: CoreAssignee: Philipe Mulet <philippe_mulet>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.1   
Target Milestone: 3.1 M7   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Philipe Mulet CLA 2005-05-11 06:10:34 EDT
Build 20050509

According to JLS 4.8 (3rd edition), all non-static member types of a raw type
should be considered as raw type. As such an unchecked warning is expected for
the following testcase:

public class X {
	public static void main(String[] args) {
		Outer.Inner inner = new Outer().new Inner();
		X x = inner.setOuterT(new X());
	}
}

class Outer<T> {
	T t;
	class Inner {
		T setOuterT(T t1) {
			t = t1;
			return t;
		}
	}
}
Comment 1 Philipe Mulet CLA 2005-05-11 06:11:48 EDT
Added GenericTypeTest#test647.
Comment 2 Philipe Mulet CLA 2005-05-11 13:16:23 EDT
Tuned raw conversion to create RawTypeBinding in this situation instead of
ParameterizedTypeBinding.
Also fixed compatibility rules to be stricter on enclosing types.
Fixed
Comment 3 Philipe Mulet CLA 2005-05-11 18:07:20 EDT
Fixed
Comment 4 Olivier Thomann CLA 2005-05-12 13:09:58 EDT
Verified in I20050510-0010 + JDT/Core v_556