eol
[mcs.git] / tests / gtest-303.cs
blob3f57bb33238f937c121f7fbf15a1eb5ada8ff8fd
1 //
2 // Test case from bug 80518
3 //
5 using System;
7 namespace test
9 public class BaseClass
11 public BaseClass()
14 public string Hello { get { return "Hello"; } }
17 public abstract class Printer
19 public abstract void Print<T>(T obj) where T: BaseClass;
22 public class PrinterImpl : Printer
24 public override void Print<T>(T obj)
26 Console.WriteLine(obj.Hello);
30 public class Starter
32 public static void Main( string[] args )
34 BaseClass bc = new BaseClass();
35 Printer p = new PrinterImpl();
36 p.Print<BaseClass>(bc);