I need System.Collections.Immutable interfaces such as IImmutableList to be covariant just like IReadOnlyList, IEnumerable in order to be able to write stuff like this:
public interface IResources<out T> where T : IDomainEntity
{
IImmutableList<T> ShouldWorkButCompilerGivesErrorDueToIImmutableListNotCovariant { get; }
IReadOnlyList<T> Works { get; }
}
I need System.Collections.Immutable interfaces such as IImmutableList to be covariant just like IReadOnlyList, IEnumerable in order to be able to write stuff like this: