update readme (#21797)
[mono-project.git] / mcs / errors / cs0457-3.cs
blob3a8175d49f706ed25f955394f819237cb3d3c680
1 // CS0457: Ambiguous user defined operators `D.implicit operator A(D)' and `C.implicit operator B(C)' when converting from `D' to `B'
2 // Line: 30
4 class A
8 class B : A
12 class C
14 public static implicit operator B (C s)
16 return new B ();
20 class D : C
22 public static implicit operator A (D s)
24 return new B ();
27 public static void Main ()
29 D d = new D ();
30 B b2 = (B) d;