In class/Microsoft.Build.Tasks/Microsoft.Build.Tasks:
[mcs.git] / tests / test-207.cs
blob6dc033e1fb9a9b47adda509e0ddcb5800b85c61d
1 using System;
3 delegate void Test (int test);
5 class X
7 static int result = 0;
9 public static void hello (int arg)
11 result += arg;
14 public static void world (int arg)
16 result += 16 * arg;
19 public static int Main ()
21 Test a = new Test (hello);
22 Test b = new Test (world);
24 (a + b) (1);
25 if (result != 17)
26 return 1;
28 ((result == 17) ? a : b) (2);
29 if (result != 19)
30 return 2;
32 ((result == 17) ? a : b) (2);
33 if (result != 51)
34 return 3;
36 return 0;