System.Windows.Threading.Dispatcher.BeginInvoke in Silverlight has an overload 
which takes a System.Action.  In .NET 3.5 it seems to only have overloads which 
take Delegate.  So on the desktop CLR we don't have any idea of what type of 
delegate to convert it to vs. Silverlight we know to go to Action.

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dan Eloff
Sent: Thursday, November 20, 2008 8:12 PM
To: Discussion of IronPython
Subject: Re: [IronPython] More fun with delegates

On Thu, Nov 20, 2008 at 4:33 PM, Srivatsn Narayanan
<[EMAIL PROTECTED]> wrote:
> Hi Dan,
>
>  The parameterless Action is actually defined in System.Core.dll so you need 
> to reference that. The crash ofcourse needs to be fixed. There is already a 
> bug on that - 
> http://www.codeplex.com/IronPython/WorkItem/View.aspx?WorkItemId=19133
>

Ok, I understand that now. But what about this?

>>> def echo(x):
...     print x
...
>>> d.BeginInvoke(echo, 2)
TypeError: expected Delegate, got function

It works fine on Silverlight.

Thanks,
-Dan
_______________________________________________
Users mailing list
[email protected]
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
_______________________________________________
Users mailing list
[email protected]
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com

Reply via email to