public abstract class Class1<T> { }
public class DerivedC1 : Class1<int> { }
public static void Main()
Type baseType = typeof(DerivedC1).BaseType;
Type baseGenericTypeDefinition = baseType.GetGenericTypeDefinition();
bool isAssignable = typeof(Class1<>).IsAssignableFrom(baseGenericTypeDefinition);
Console.WriteLine($"Is Class1<> assignable from the base type of DerivedC1: {isAssignable}");