Merge pull request #495 from nicolas-raoul/fix-for-issue2907-with-no-formatting-changes
[mono.git] / mcs / tests / test-anon-24.cs
1 using System;
2
3 delegate int D ();
4
5 class X {
6
7         public static void Main ()
8         {
9                 D x = T (1);
10
11                 Console.WriteLine ("Should be 2={0}", x ());
12         }
13
14         static D T (int a)
15         {
16                 D d = delegate {
17                         a = a + 1;
18                         return a;
19                 };
20
21                 return d;
22         }
23 }