2010-06-17 Geoff Norton <gnorton@novell.com>
[mono.git] / mono / tests / nullable_boxing.2.cs
blob86a31eb67113c66106ac59c676b0222ae5974815
1 using System;
3 public class Program {
5 internal class Button : ContextBoundObject
7 public int Counter (int? x)
9 if (x == null)
10 return 0;
11 return x.Value + 1;
14 public static Button TheButton = new Button ();
17 public static int Main ()
19 // Test remoting and nullables
20 if (Button.TheButton.Counter (1) != 2)
21 return 1;
23 int?[] x = new int?[] { null };
24 return x.GetValue (0) == null ? 0 : 2;