linux-packaging-mono/mcs/tests/test-anon-32.cs
Jo Shields a575963da9 Imported Upstream version 3.6.0
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
2014-08-13 10:39:27 +01:00

23 lines
432 B
C#

public delegate void StringSender (string str);
public delegate void VoidDelegate ();
public class MainClass
{
public static void Main()
{
MainClass mc = new MainClass ();
VoidDelegate del = new VoidDelegate (delegate {
StringSender ss = delegate (string s) {
SimpleCallback(mc, s);
};
ss("Yo!");
});
del();
}
static void SimpleCallback (MainClass mc, string str)
{
System.Console.WriteLine(str);
}
}