public void TestImplicitCastExtension() { Integer i = new Integer(42); RuntimeServices.WithExtensions(typeof (IntegerExtensions), delegate { Assert.AreEqual(42, Coerce(i, typeof (int))); }); }
public static int op_Implicit(Integer i) { return i.Value; }