Pragma mangle and D shared objects

Etienne Cimon via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sun Oct 26 11:25:11 PDT 2014


On 2014-10-25 23:31, H. S. Teoh via Digitalmars-d-learn wrote:
> Hmm. You can probably use __traits(getAllMembers...) to introspect a
> library module at compile-time and build a hash based on that, so that
> it's completely automated. If you have this available as a mixin, you
> could just mixin(exportLibrarySymbols()) in your module to produce the
> hash.

Exactly, or I could also make it export specific functions into the 
hashmap, a little like a router. It seems like a very decent option.



More information about the Digitalmars-d-learn mailing list