Merge pull request #496 from nicolas-raoul/unit-test-for-issue2907
[mono.git] / mcs / tests / gtest-122.cs
1     class Test
2     {
3         public static void Main(string[] args)
4         {
5             A<int> a = new A<int>(new A<int>.B(D), 3);
6             a.Run();
7         }
8         public static void D(int y)
9         {
10             System.Console.WriteLine("Hello " + 3);
11         }
12     }
13     class A<T>
14     {
15         public delegate void B(T t);
16
17         protected B _b;
18         protected T _value;
19
20         public A(B b, T value)
21         {
22           _b = b;
23           _value = value;
24       }
25         public void Run()
26         {
27             _b(_value);
28         }
29     }
30