internal static Type VerifyConcreteClass(Type sourceType, Type resultType) { if (resultType == null) { return(null); } var result = resultType.GetTypeInfo(); if (result != null && (result.IsAbstract || result.IsInterface || !sourceType.GetTypeInfo().IsAssignableFrom(result))) { throw RuntimeFailure.ConcreteClassError(resultType); } return(resultType); }