Consider given example:
class Create {
Create(int num) {}
Create(Integer num) {}
public static void test(int... a) { }
public static void test(Integer... a) { }
public static void main(String[] args) {
new Create(1); // ok
Create.test(1); // error: reference to test is ambiguous
}
}
Can someone explain me what is the difference for compiler in these two cases?