Welcome to mirror list, hosted at ThFree Co, Russian Federation.

test-126.cs « tests « mcs - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 26ed4190a206e8f9dedd72e06833525f2cafbb1b (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 () {} 
	
	static int Main ()
	{
		X x = new X ();
		Iface f = x;

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

		return 0;
	}
}