[Checkers] @Raw in the nullness type qualifier hierarchy

Mahmood Ali mahmood at MIT.EDU
Mon May 25 01:24:49 EDT 2009


Greetings,

> In particular, I could have a reference that is
> nullable and raw, or one that is non-null and raw.

What does it mean for a reference to be nullable and raw?  In your  
understanding, can you have a type that is both nullable and not-raw?

I think we have different meanings for NonNull and Raw.  My  
understanding is the following:
1. Nullable: the type could representing a null reference.
2. NonNull: the type could represent a not null reference whose fields  
are properly initialized.  This is typically the case when a  
constructor is fully executed (or after all the fields have been  
initialized)
3. Raw: the type could represent a not-null reference whose fields are  
not fully initalized.  This is usually the case during the execution  
of a constructor.

In this understanding, each annotation is disjoin annotation, with the  
following subtype hierarchy: nonnull < raw < nullable.

Regards,
Mahmood




More information about the checkers mailing list