[2019-12] [threads] Add back mono_threads_attach_tools_thread as a public API (#18074)
[mono-project.git] / mono / tests / delegate5.cs
blob8ad8b86056a5584cd3ac2ea8271ddbdfe238fa4c
1 using System;
2 using System.Threading;
3 using System.Runtime.Remoting;
4 using System.Runtime.Remoting.Messaging;
6 public class T21
8 public delegate void TestCallback (int i);
10 public static void Test (int i)
12 Console.WriteLine (i);
15 public static void Main ()
17 TestCallback cb = new TestCallback (Test);
18 IAsyncResult ar = cb.BeginInvoke (100, null, null);
19 ar.AsyncWaitHandle.WaitOne ();
20 cb.EndInvoke (ar);