summaryrefslogtreecommitdiff
path: root/mcs/tests/test-126.cs
blob: fd3f6d11ad46473bf978c1811d30b2a5182eaa6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//
// It is possible to invoke object methods in an interface.
//
using System;

interface Iface {
	void Method ();
}

class X : Iface {

	void Iface.Method () {} 
	
	public static int Main ()
	{
		X x = new X ();
		Iface f = x;

		if (f.ToString () != "X")
			return 1;

		return 0;
	}
}