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

test-197.cs « tests « mcs - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 4d9d217de7add16ec9fd95c8ce6ab6f5abd30c69 (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
25
26
27
28
29
30
31
32
33
34
35
36
using System;

public interface A
{
	void Foo ();
}

public interface B : A
{ }

public abstract class X : A
{
	public abstract void Foo ();
}

public abstract class Y : X, B
{ }

public class Z : Y
{
	public override void Foo ()
	{
		Console.WriteLine ("Hello World!");
	}
}

class Test
{
	public static int Main ()
	{
		Z z = new Z ();
		A a = z;
		a.Foo ();
		return 0;
	}
}