* delegate.cs: Add test for unboxing and delegates.
svn path=/trunk/mono/; revision=37093
+2004-12-04 Zoltan Varga <vargaz@freemail.hu>
+
+ * delegate.cs: Add test for unboxing and delegates.
+
2004-12-02 Zoltan Varga <vargaz@freemail.hu>
* appdomain-unload.cs: Add tests for unloading an appdomain from inside
delegate void SimpleDelegate ();
delegate string NotSimpleDelegate (int a);
delegate int AnotherDelegate (string s);
+
+ delegate string StringDelegate ();
public int data;
Console.WriteLine (d4.Method);
Console.WriteLine (d4.Method.Name);
Console.WriteLine (d4.Method.DeclaringType);
+
+ // Check unboxing of this argument
+ int x = 10;
+ StringDelegate d5 = new StringDelegate (x.ToString);
+ if (d5 () != "10")
+ return 1;
return 0;