With method signatures like:
public interface TestInterface
{
void SampleMethodOut(out int? nullableInt);
void SampleMethod(int? nullableInt);
}
I’m using typeof(TestInterface).GetMethods()[1].GetParameters()[0].ParameterType to get the type, and then checking IsGenericType and Nullable.GetUnderlyingType. How can I do this with the method with the out parameter?
Doh, ignore my previous answer.
You use
Type.IsByRef, and callType.GetElementType()if so: