The compiler may produce a *warning* but not an error if a static member of a class is being accessed by its instance though its suggested to be used with the ClassName - thats what the purpose is.
Note however that the instance isn't actually dereferenced. The following code will not throw a NullPointerException
code:
--------------------------------------------------------------------------------
Test t1= null;System.out.println(t1.total);
--------------------------------------------------------------------------------
Thats a good point Joanne Neal