public void Test() { //Covariance<Base> coB = new CoContraVarianceCollection(); //Covariance<Derived> coD = coB; Covariance <Derived> coD = new CoContraVariance(); Covariance <Base> coB = coD; //Contravariance<Derived> contraD = new CoContraVarianceCollection(); //Contravariance<Base> contraB = contraD; Contravariance <Base> contraB = new CoContraVariance(); Contravariance <Derived> contraD = contraB; }
public static CoContraVariance GetVariances() => _coll ?? (_coll = new CoContraVariance());