Stephan van Hulst wrote:It doesn't. Java always decides which methods to use at compile time. The method calls are hardcoded into the program. Example:
This will print "I got an object!"
Rob Spoor wrote:What's the error you get? Is it perhaps the varargs on line 16?
Helios has it right. Older versions do not give a compile error, while they should...
Rob Spoor wrote:...Every compiler should fail compilation. If one doesn't then that compiler is actually broken.