In C# the following is valid:
public class X {
public void F<T>(T t) {}
}
and do:
var x = new X();
x.F(2);
and that’s not possible in Java.
I know generics work different in both languages, but I’m still wondering…
Is there a good reason for that?
The syntax is different: