a575963da9
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
20 lines
318 B
C#
20 lines
318 B
C#
public class A {
|
|
public static implicit operator double (A a)
|
|
{
|
|
return 0.5;
|
|
}
|
|
|
|
// unlike CS0034 case, two or more implicit conversion on other
|
|
// than string is still valid.
|
|
public static implicit operator int (A a)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
public static void Main ()
|
|
{
|
|
A a = new A ();
|
|
object p = a + a;
|
|
}
|
|
}
|