[mcs] C#7 throw expression
[mono.git] / mcs / tests / test-935.cs
index c47d89dc628e655e1a7f3f42a32a410dcd3491fb..6afe80eb0d024cfe07e01528e7d4c586509e5699 100644 (file)
@@ -15,6 +15,9 @@ public static class Program
                NN (0);
                NN2 (1);
                Complex (null);
+               MM (1);
+               MM ((byte) 1);
+               DecimalRule (() => (byte) 1);
                return 0;
        }
 
@@ -71,4 +74,22 @@ public static class Program
        {
                throw new ApplicationException ("wrong overload");
        }
+
+       static void MM (double f)
+       {
+       }
+
+       static void MM (double? f)
+       {
+               throw new ApplicationException ("wrong overload");
+       }
+
+    static void DecimalRule (Func<int> i)
+    {
+    }
+
+    static void DecimalRule (Func<decimal?> i)
+    {
+        throw new ApplicationException ("wrong overload");
+    }
 }
\ No newline at end of file