Bump mono-extensions to fix build break (#5677)
[mono.git] / mcs / tests / test-285.cs
index 133f9daf1388711d771727e3bbd2e76bc1756936..c49949b239ac575543d245d6b734788fd7c941be 100644 (file)
@@ -1,11 +1,42 @@
-class T {
-       static int Main ()
+class Test
+{
+       static int test1 ()
+       {
+               var s = "Nice";
+               switch (s) {
+               case "HI":
+                       const string x = "Nice";
+                       return 1;
+               case x:
+                       return 2;
+               }
+
+               return 3;
+       }
+
+       public const string xx = "Not";
+       static int test2 ()
        {
-               switch (1) {
-               case 1:
-                       return 0;
-               default:
-                       break;
+               var s = "Nice";
+               switch (s) {
+               case "HI":
+                       const string xx = "Nice";
+                       return 1;
+               case xx:
+                       return 2;
                }
+
+               return 3;
+       }
+
+       static int Main ()
+       {
+               if (test1 () != 2)
+                       return 1;
+
+               if (test2 () != 2)
+                       return 2;
+
+               return 0;
        }
-}
+}
\ No newline at end of file