When I compile my NaturalLanguageMultiply I get a warning telling me that "Note: NaturalLanguageMultiply.java uses unsafe or unchecked operations. Note: Recompile with -Xlint for details."
It seems to not like lines like this "myHash.put( "ninety" , new Integer (90) ) ; " Am I doing something wrong that might cause me problems down the road? Since it's just a warning, the program still compiles and runs, but I know somethings not right here.
It's not a problem. Because you are using a java 5 compiler to compile code that is written for java 4, it gives you a warning. As an experiment, try compiling using javac -source 1.4 and see if you get the same warnings.
JavaBeginnersFaq "Yesterday is history, tomorrow is a mystery, and today is a gift; that's why they call it the present." Eleanor Roosevelt
Joined: Mar 06, 2006
Thanks for the reply, Marilyn! And as ususal, you're right and compiling w/ -source 1.4 produced no errors.
Now, another question, you said I'm writing code for Java 4. What "feature" makes this Java 4 code and not Java 5. Is it the HashMap?
Marilyn de Queiroz
Joined: Jul 22, 2000
Yes, any of the Collections including Maps, Lists and Sets.