[JSR308] Raw Types and AnnotatedTypeFactory

Niko Matsakis niko at alum.mit.edu
Thu Mar 26 07:38:07 EDT 2009

> Addressing this has not been a priority for us.  We think that  
> proper use
> of generics is important to type safety, so we wish to encourage  
> it.  We
> expect that people who are willing to run a pluggable type-checker  
> will be
> willing to first ensure type-safety with respect to Java's built-in  
> type
> system (including generics).  And, our implementation (of both the  
> Checker
> Framework and of the checkers themselves) is made simpler by  
> assuming that
> there are no raw types.

In general, I agree with you that most people using a pluggable type
system will also be working with fully generified-code.  However, even
the most gung-ho type system adopter may occasionally have to interface
with legacy code that makes use of raw types.  Therefore, it'd be good  
the framework handled them gracefully.  They are after all a part of the
Java language, for better or worse.

In any case, after changing the framework not to insert dummy types for
missing type arguments, I have (so far!) not had any problems... but I  
done a lot of work with raw typed programs, just a little.


More information about the JSR308 mailing list