On Thursday, March 07, 2013 13:48:21 Walter Bright wrote: > My idea for this is straightforward. A D plugin should use a C interface. > That means, for example, that a D plugin should NOT pass GC allocated > references to its caller. Only malloc'd data should pass between the plugin > and its caller. > > The D plugin could still use the shared druntime.so, and could share that > usage with the D caller of the plugin.
That may very well end up being a necessary restriction, but not being able to pass GC allocated objects across library boundaries would be a _huge_ downside to using shared libraries if that happens. It also would likely be a major source of bugs as it's pretty much a guarantee that a lot of people would do it unless the compiler prevented them in some manner. - Jonathan M Davis
