Bump NuGet.BuildTasks to get new updates and switch to `dev` branch (#5566)
[mono.git] / mcs / tests / gtest-274.cs
index baa4e39536d05d44bf9663031e049dbd811df01f..30f4d3c5b4a53d02556a4f0205724850da3737d6 100644 (file)
@@ -45,9 +45,17 @@ public struct Baz
        }
 }
 
+struct S
+{
+       public static implicit operator bool?(S arg)
+       {
+               throw new ApplicationException ("should not be called");
+       }
+}
+
 class X
 {
-       static void Main ()
+       public static int Main ()
        {
                int a = 3;
                int? b = a;
@@ -67,5 +75,12 @@ class X
                Baz? z2 = (Baz?) f2;
                Baz? z3 = (Baz?) f3;
                Baz z4 = (Baz) f2;
+
+               S? s = null;
+               bool? g = s;
+               if (g != null)
+                       return 1;
+
+               return 0;
        }
 }