Shared libraries/DLLs
bearophile
bearophileHUGS at lycos.com
Mon Feb 4 01:15:31 PST 2008
Jarrett Billingsley:
> However there's hope: DDL. http://www.dsource.org/projects/ddl
It looks really nice.
Regarding the Quick DDL Tutorial:
http://www.dsource.org/projects/ddl/wiki/Tutorial/UsingDDL/Quick
I think the interface may be eventually simplified to something like this (it may perform the "dmd -c plugin.d" too if needed):
import std.stdio, ddl;
void main(){
auto plugin = dlink("plugin.d");
if (plugin.hasFunction("helloWorld")) {
auto hello = plugin.Func!(string function(), "helloWorld");
writefln(hello());
}
}
(Or/and equivalent for Tango).
Bye,
bearophile
More information about the Digitalmars-d-learn
mailing list