As other answers showed, you can do this if the arguments of your function type match the parameters of the class type.
If they do not match, this is not possible because your example will violate type safety. Consider the following example:
A1 a = new A2(); ... a.Generic<string, string>("", "");
This is a legal challenge since A1 provides Generic<T, U>(T t, U u) . But at runtime, we have a problem, since the dynamic type of a is A2 , and the version in A2 only supports int as the second parameter.
source share