[mono/tests] Fix out of tree build.
[mono-project.git] / mcs / tests / test-935.cs
blob6afe80eb0d024cfe07e01528e7d4c586509e5699
1 using System;
2 using System.Threading.Tasks;
3 using System.Linq.Expressions;
5 public static class Program
7 public delegate void DelegateVoid (int arg);
8 public delegate int DelegateInt (string arg);
10 public static int Main ()
12 Foo (Bar);
14 TT (null);
15 NN (0);
16 NN2 (1);
17 Complex (null);
18 MM (1);
19 MM ((byte) 1);
20 DecimalRule (() => (byte) 1);
21 return 0;
24 static void TT (Task<string> a)
28 static void TT (Task<object> b)
30 throw new ApplicationException ("wrong overload");
33 static void NN (sbyte a)
37 static void NN (uint? b)
39 throw new ApplicationException ("wrong overload");
42 static void NN2 (sbyte? a)
46 static void NN2 (uint? b)
48 throw new ApplicationException ("wrong overload");
51 public static void Bar (int arg)
55 public static int Bar (string arg)
57 return 2;
60 public static void Foo (DelegateVoid input)
62 throw new ApplicationException ("wrong overload");
65 public static void Foo (DelegateInt input)
69 static void Complex (Expression<Func<Task<short>>> arg)
73 static void Complex (Expression<Func<Task<ulong>>> arg)
75 throw new ApplicationException ("wrong overload");
78 static void MM (double f)
82 static void MM (double? f)
84 throw new ApplicationException ("wrong overload");
87 static void DecimalRule (Func<int> i)
91 static void DecimalRule (Func<decimal?> i)
93 throw new ApplicationException ("wrong overload");