I type Integer.parseInt("37") in the CodePad and get 37, as expected.
I type Integer.parseInt("37.6") in the CodePad and get a NumberFormatException,
I type Integer.parseInt(37) in the CodePad; I would expect to get an error
message saying "wrong type argument" or "no such method found", but in fact I
get "semicolon expected".
BLUEJ-1 From Davin McCall 2006-08-31 02:24:31
Yes, this is not ideal (currently anything which doesn't compile as an
expression is treated as a statement, and as statements must end with a
semicolon, the error message demands one). For a simple case like the example
given, we should be able to do better.