On Thu, Jun 9, 2011 at 6:34 PM, Alexander Turner <nerdscent...@googlemail.com> wrote: > Robert, > > I am not sure I agree here. The vargs method is not defining the type > of the arguments. Therefore their type is actually Object. Thus we are > comparing int to Object. int is more specific.
int is not more specific. int is not a subtype of Object. In Java (and in the JVM) there is not a "top" type (that is, a type which is a supertype of every other type). This was, I believe, a design mistake, but we can't do anything about it. Alessio -- You received this message because you are subscribed to the Google Groups "JVM Languages" group. To post to this group, send email to jvm-languages@googlegroups.com. To unsubscribe from this group, send email to jvm-languages+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/jvm-languages?hl=en.