[Mono-osx] MonoMac: on demand loading
Geoff Norton
gnorton at novell.com
Sun Sep 19 12:31:21 EDT 2010
On 2010-09-19, at 12:26 PM, Miguel de Icaza wrote:
> Hello,
>
> Currently most libraries are force loaded from NSObjectMac.cs. Even though they are shared it still might be better to only load libraries used by the app. I theorized a solution by adding a static ctor in each class within the namespace that would load the library, but I believe this will not work as the library must be initialized first so it can be registered.
>
> Yes, this is one of our to-do list items; I think Geoff had some ideas on how to handle this.
>
I was thinking of maybe using module initializers here, but we'd need to do some compiler embrace/extend to support that, so I'm wondering if there isn't something more elegant we can do. We could probably use the type load event to load the librarys with a NS->Framework mapping, but that doesn't help user-code much.
-g
> Miguel
>
>
>
> _______________________________________________
> Mono-osx mailing list
> Mono-osx at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-osx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-osx/attachments/20100919/b94a82cd/attachment.html
More information about the Mono-osx
mailing list