Definitely weird. It sounds like it's a post-1.5 compiler with a pre-1.5 standard library. Is there any chance you've got another JDK or JRE on the classpath, and the class definition is being taken from there?
keshav pradeep ramanath wrote:So i believe its that main it is referring to.
No, I don't think so. It sounds to me that if indeed you have a class called 'main' (which is wrong; class names should start with CAPITAL letters), you've defined a class called HashMap inside it. Alternatively, you have a package called 'main' that defines a HashMap class.