summaryrefslogtreecommitdiff
path: root/mcs/errors/cs0029-13.cs
blob: 9d705b290e63fc2c0c8610380748a76765066098 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// CS0029: Cannot implicitly convert type `int' to `A'
// Line: 14

class A
{
	public static implicit operator int (A x)
	{
		return 1;
	}
	
	public static void Main ()
	{
		var a = new A ();
		a++;
	}
}