In case it's interesting or useful, I've attached some p/Invoke stuff I was playing with before I got derailed by the DefineDynamicAssembly problem and then joined Microsoft :).<br><br>
<div class="gmail_quote">On Sat, Mar 21, 2009 at 10:45 AM, Dino Viehland <span dir="ltr"><<a href="mailto:dinov@microsoft.com">dinov@microsoft.com</a>></span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">If you only have 1 method and don't need overload resolution I'd suggest making a delegate using System.Delegate.CreateDelegate. Otherwise this could be made public.<br>
<div>
<div></div>
<div class="h5"><br>> -----Original Message-----<br>> From: <a href="mailto:users-bounces@lists.ironpython.com">users-bounces@lists.ironpython.com</a> [mailto:<a href="mailto:users-">users-</a><br>> <a href="mailto:bounces@lists.ironpython.com">bounces@lists.ironpython.com</a>] On Behalf Of Jeff Hardy<br>
> Sent: Saturday, March 21, 2009 9:44 AM<br>> To: Discussion of IronPython<br>> Subject: Re: [IronPython] Creating Dynamic Assemblies from IronPython<br>> 2.6<br>><br>> Thanks Curt, that worked. Now I have a new problem - I can get a<br>
> MethodInfo, but I need to be able to convert it to something I can<br>> call. Seo's old code used BuiltinFunction.MakeOrAdd, but that is now<br>> internal. Can this be made public, or is there a better way to handle<br>
> it?<br>><br>> - Jeff<br>><br>> 2009/3/20 Curt Hagenlocher <<a href="mailto:curt@hagenlocher.org">curt@hagenlocher.org</a>>:<br>> > I think this is something that broke well before the 2.0 release. To<br>
> work<br>> > around it in pyc.py, we added DefineDynamicAssembly to the PythonOps<br>> class<br>> > in IronPython:<br>> ><br>> > import clr<br>> > clr.AddReference('IronPython')<br>
> > from IronPython.Runtime.Operations import PythonOps<br>> > assemblyBuilder = PythonOps.DefineDynamicAssembly(...)<br>> ><br>> _______________________________________________<br>> Users mailing list<br>
> <a href="mailto:Users@lists.ironpython.com">Users@lists.ironpython.com</a><br>> <a href="http://lists.ironpython.com/listinfo.cgi/users-ironpython.com" target="_blank">http://lists.ironpython.com/listinfo.cgi/users-ironpython.com</a><br>
_______________________________________________<br>Users mailing list<br><a href="mailto:Users@lists.ironpython.com">Users@lists.ironpython.com</a><br><a href="http://lists.ironpython.com/listinfo.cgi/users-ironpython.com" target="_blank">http://lists.ironpython.com/listinfo.cgi/users-ironpython.com</a><br>
</div></div></blockquote></div><br>