[Mono-bugs] [Bug 24653] New - asynchronous delegates

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
13 May 2002 22:58:20 -0000


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by loz@cable.a2000.nl.

http://bugzilla.ximian.com/show_bug.cgi?id=24653

--- shadow/24653	Mon May 13 18:58:20 2002
+++ shadow/24653.tmp.18691	Mon May 13 18:58:20 2002
@@ -0,0 +1,63 @@
+Bug#: 24653
+Product: Mono/Runtime
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: loz@cable.a2000.nl               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: asynchronous delegates
+
+I copied-and-pasted the exact example from "Asynchronous Delegates 
+Programming Sample" from the .Net developers guide, which worked fine in 
+mono, but didn't with mint.
+
+I tried to minimize the code to what you see below. But that one fails in 
+both mint and mono, yet works fine with ms.net. Mono gives the following 
+error:
+
+ (process:648):** ERROR **: file delegate.c: line 93 (mono_async_invoke): 
+assertion failed: (ac->res) aborting...
+
+Mint gives the following error:
+
+ (process:1744):** ERROR &&: Don't know how to exec runtime 
+method .TestCallback::BeginInvoke aborting...
+
+The code:
+
+using System;
+using System.Threading;
+using System.Runtime.Remoting;
+using System.Runtime.Remoting.Messaging;
+
+public class T21
+{
+	public delegate void TestCallback (int i);
+	
+	public static void Test (int i)
+	{
+		Console.WriteLine (i);
+	}
+	
+	public static void Main ()
+	{
+		TestCallback cb = new TestCallback (Test);
+		IAsyncResult ar = cb.BeginInvoke (100, null, null);
+		ar.AsyncWaitHandle.WaitOne ();
+		cb.EndInvoke (ar);
+      }
+}
+
+
+
+Greets,
+Lawrence