public static void TestI10() { var c17 = new C17(); C16 c16 = c17; I10 i10 = c17; c17.Foo(); Assert.AreEqual("C17", c17.log); c17.log = null; c16.Foo(); Assert.AreEqual("C16", c17.log); c17.log = null; i10.Foo(); Assert.AreEqual("C16", c17.log); }
void M5 <T>(C16 <T, int> c) where T : class { // Viable callables: {C16,C17}.M1() c.M2(() => default(T)); }
void M4 <T>(C16 <T, int> c) where T : struct { // Viable callable: C16.M2() [also reports C17.M2(); false positive] c.M2(() => default(T)); }