Bug 115181 - [1.5][compiler] Wrongly flagged "Usage of a raw type"
Summary: [1.5][compiler] Wrongly flagged "Usage of a raw type"
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 minor (vote)
Target Milestone: 3.2 M4   Edit
Assignee: Philipe Mulet CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 115222 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-11-04 18:27 EST by John Liu CLA
Modified: 2005-12-13 07:50 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Liu CLA 2005-11-04 18:27:00 EST
Eclipse 3.2M3 has a static code check for "Usage of a raw type" that sometimes 
flags certain ".class" values with a warning.  See code below.

import java.util.Comparator;
public class TestClass {
   public static void test( Class<?> clazz ) {}
   public static void test() {
      test(Comparator.class); // WARNING HERE
   }
}
Comment 1 Philipe Mulet CLA 2005-11-05 07:01:08 EST
Agreed. The parameterized syntax is disallowed there, so it should not blame for
raw type reference.
Comment 2 Philipe Mulet CLA 2005-11-05 07:06:37 EST
Added GenericTypeTest#test868.
Fixed
Comment 3 Olivier Thomann CLA 2005-11-06 15:07:57 EST
*** Bug 115222 has been marked as a duplicate of this bug. ***
Comment 4 Frederic Fusier CLA 2005-12-13 07:50:27 EST
Verified for 3.2 M4 using build I20051213-0010